File tree Expand file tree Collapse file tree 4 files changed +36
-0
lines changed
Expand file tree Collapse file tree 4 files changed +36
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Run tests and upload coverage
2+ on :
3+ push
4+ jobs :
5+ test :
6+ name : Run tests and collect coverage
7+ runs-on : ubuntu-latest
8+ steps :
9+ - name : Checkout
10+ uses : actions/checkout@v4
11+ with :
12+ fetch-depth : 0
13+ - name : Set up Python
14+ uses : actions/setup-python@v4
15+ - name : Install dependencies
16+ run : pip install pytest pytest-cov
17+ - name : Run tests
18+ run : pytest --cov=. --cov-report=xml --cov-branch
19+ - name : Upload results to Codecov
20+ uses : codecov/codecov-action@v5
21+ with :
22+ token : ${{ secrets.CODECOV_TOKEN }}
23+ slug : swthewhite/python-baseball
Original file line number Diff line number Diff line change 1+ ## 기능 추가
2+ 1 . 1에서 9까지 서로 다른 임의의 수 3개 생성 기능 추가 (2025/02/04)
Original file line number Diff line number Diff line change 1+ import random
2+
3+ def make_computer_num ():
4+ computer = random .sample (range (1 , 9 ), 3 )
5+ return computer
6+
17def main ():
28 """
39 프로그램의 진입점 함수.
410 여기에서 전체 프로그램 로직을 시작합니다.
511 """
612 # 프로그램의 메인 로직을 여기에 구현
13+ print ("숫자 야구 게임을 시작합니다." )
14+ computer = make_computer_num ()
15+ print (computer )
716
817if __name__ == "__main__" :
918 # 프로그램이 직접 실행될 때만 main() 함수를 호출
1019 main ()
20+
21+
File renamed without changes.
You can’t perform that action at this time.
0 commit comments