-
Notifications
You must be signed in to change notification settings - Fork 455
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[자동차 경주] 진찬용 미션 제출합니다. #444
Open
Jin-Chanyong
wants to merge
21
commits into
woowacourse-precourse:main
Choose a base branch
from
Jin-Chanyong:Jin-Chanyong
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
[자동차 경주] 진찬용 미션 제출합니다. #444
Jin-Chanyong
wants to merge
21
commits into
woowacourse-precourse:main
from
Jin-Chanyong:Jin-Chanyong
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
README.md 에 이하 내용 추가: - 기능 요구 사항 - 기능 목록 단위
userInput.js 파일에 이하 내용 추가: - 자동차 이름을 입력받고, ',' 로 분리한 배열을 반환하는 함수 구현
throwError.js 파일에 이하 내용 추가: - 일관된 에러 메시지 형식을 유지하기 위한 에러 발생 함수 추가
inputValidator.js 파일에 이하 내용 추가: - 중복 이름, 공백 이름, 좌우 공백 여부, 이름 길이 조건들을 검사하는 자동차 입력값 유효성 검사 함수 추가
car.js 파일에 이하 내용 추가: - car 개체의 클래스 생성 - 자동차의 이동과 진행사항을 관리하는 메서드 포함
userInput.js 파일의 이하 내용 변경: - 어떤 기능을 하는지 명확히 하기 위해 carNameInputHandler -> getValidatedCars 로 이름 변경 - getValidatedCars 함수가 각 자동차 이름의 인스턴스를 가진 배열을 반환하도록 변경
inputValidator.js 파일에 이하 내용 추가: - 입력값이 빈 값인지, 올바른 값을 입력했는지, 자연수가 아닌 수를 입력했는지를 확인하는 유효성 검사 함수 추가 - 유효성 검사가 성립하지 않으면 오류가 발생한다.
userInput.js 파일에 이하 내용 추가: - 횟수를 사용자로부터 입력받고, 유효한 값인지를 판별 후 횟수를 반환하는 getValidatedCount 함수 추가
getRandomDigit.js 파일에 이하 내용 추가: - 0 과 9 사이의 정수 난수를 반환하는 getRandomDigit 함수 추가
startRace.js 파일에 이하 내용 추가: - 0과 9 사이의 정수 난수를 발생시켜, 4 이상인 경우 자동차를 움직이도록 하는 함수 추가
startRace.js 파일에 이하 내용 추가: - 자동차의 진행상황을 시각적으로 보여주도록 출력하는 함수 viewProgressBar 함수 추가
startRace.js 파일에 이하 내용 추가: - 경주 참가자들의 최대 distance 를 구하여, 이를 통해 우승자들의 이름 배열을 반환하는 getWinners 함수 구현
startRace.js 파일에 이하 내용 추가: - 자동차 경주 전반의 로직을 구성하는 함수 startRace 함수 추가 - 경주 진행상황과 최종 우승자 출력 포함
App.js 파일에 이하 내용 추가: - 사용자의 입력값을 받아 경주를 실행하는 코드 추가
inputValidator.js, startRace.js, userInput.js 파일에 이하 내용 수정: - import 경로의 파일명 뒤 확장자 .js 추가
inputValiator.js 파일에 이하 내용 수정: - countValidate 함수의 isNaN 메소드 사용 오류 수정
startRace.js 파일에 이하 내용 수정: - viewProgressBar 함수에서 getProgressBar 메소드를 실행하도록 수정
startRace.js 파일에 이하 내용 수정: - getWinners 함수에서 car 의 distance 프로퍼티를 잘못 기재하여 발생한 오류 수정
inputValidator.js 파일에 이하 내용 수정: - countValidate 함수에서 0 입력 시 오류가 발생하지 않는 문제를 수정 - 공백을 여러 개 입력하는 경우, '시도할 횟수를 입력해주세요.' 메시지가 나올 수 있도록 코드 수정
ApplicationTest.js 파일에 이하 내용 추가: - README 에 작성한 기능 요구 사항과 기능 목록 단위에 입각하여, 테스트 케이스 작성 - 사용자의 입력값에 대해 여러 예외상황에 대한 테스트 케이스 추가
README.md 파일에 이하 내용 수정: - 테스트 결과에 따라 완료된 기능 목록 체크
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
1. 자동차 이름 입력받기
2. 시도할 횟수 입력받기
3. 자동차 경주 현황 출력하기
4. 최종 우승자 출력하기
5. 테스트 코드 작성