|
| 1 | +import { |
| 2 | + AnswerChoice, |
| 3 | + MultipleChoiceQuizQuestion, |
| 4 | + QuizQuestion, |
| 5 | + QuizQuestionProvider, |
| 6 | +} from 'codedifferently-instructional'; |
| 7 | + |
| 8 | +export class ChelseaOgbonniaQuiz implements QuizQuestionProvider { |
| 9 | + getProviderName(): string { |
| 10 | + return 'chelseaogbonnia'; |
| 11 | + } |
| 12 | + |
| 13 | + makeQuizQuestions(): QuizQuestion[] { |
| 14 | + return [ |
| 15 | + ChelseaOgbonniaQuiz.makeQuestion0(), |
| 16 | + ChelseaOgbonniaQuiz.makeQuestion1(), |
| 17 | + ChelseaOgbonniaQuiz.makeQuestion2(), |
| 18 | + ChelseaOgbonniaQuiz.makeQuestion3(), |
| 19 | + ]; |
| 20 | + } |
| 21 | + |
| 22 | + private static makeQuestion0(): QuizQuestion { |
| 23 | + return new MultipleChoiceQuizQuestion( |
| 24 | + 0, |
| 25 | + 'Which git command combines the changes from one branch to the current branch?', |
| 26 | + new Map<AnswerChoice, string>([ |
| 27 | + [AnswerChoice.A, 'git branch -d <branchname>'], |
| 28 | + [AnswerChoice.B, 'git merge <branchname>'], |
| 29 | + [AnswerChoice.C, 'git branch'], |
| 30 | + [AnswerChoice.D, 'git add <filename>'], |
| 31 | + ]), |
| 32 | + AnswerChoice.UNANSWERED, |
| 33 | + ); // Replace `UNANSWERED` with the correct answer. |
| 34 | + } |
| 35 | + |
| 36 | + private static makeQuestion1(): QuizQuestion { |
| 37 | + return new MultipleChoiceQuizQuestion( |
| 38 | + 1, |
| 39 | + 'Which git command is used fetch and download content from a remote repository to update the local repository?', |
| 40 | + new Map<AnswerChoice, string>([ |
| 41 | + [AnswerChoice.A, 'git fetch'], |
| 42 | + [AnswerChoice.B, 'git merge'], |
| 43 | + [AnswerChoice.C, 'git clone'], |
| 44 | + [AnswerChoice.D, 'git pull'], |
| 45 | + ]), |
| 46 | + AnswerChoice.UNANSWERED, |
| 47 | + ); // Replace `UNANSWERED` with the correct answer. |
| 48 | + } |
| 49 | + private static makeQuestion2(): QuizQuestion { |
| 50 | + return new MultipleChoiceQuizQuestion( |
| 51 | + 2, |
| 52 | + 'Which Git command is NOT used to sync repositories?', |
| 53 | + new Map<AnswerChoice, string>([ |
| 54 | + [AnswerChoice.A, 'git push'], |
| 55 | + [AnswerChoice.B, 'git sync'], |
| 56 | + [AnswerChoice.C, 'git pull'], |
| 57 | + [AnswerChoice.D, 'git merge'], |
| 58 | + ]), |
| 59 | + AnswerChoice.UNANSWERED, |
| 60 | + ); // Replace `UNANSWERED` with the correct answer. |
| 61 | + } |
| 62 | + |
| 63 | + private static makeQuestion3(): QuizQuestion { |
| 64 | + return new MultipleChoiceQuizQuestion( |
| 65 | + 3, |
| 66 | + 'Which git command creates a new Git repository?', |
| 67 | + new Map<AnswerChoice, string>([ |
| 68 | + [AnswerChoice.A, 'git init'], |
| 69 | + [AnswerChoice.B, 'git clone'], |
| 70 | + [AnswerChoice.C, 'git folder <repositoryname>'], |
| 71 | + [AnswerChoice.D, 'git add <repositoryname>'], |
| 72 | + ]), |
| 73 | + AnswerChoice.UNANSWERED, |
| 74 | + ); // Replace `UNANSWERED` with the correct answer. |
| 75 | + } |
| 76 | +} |
0 commit comments