• 10 hours
  • Medium

Free online content available in this course.

course.header.alt.is_video

course.header.alt.is_certifying

Got it!

Last updated on 11/9/21

Follow an In-Depth Example of Creating User Stories

Log in or subscribe for free to enjoy all this course has to offer!

The OpenClassrooms Quiz

A screenshot of an old version of a quiz on OpenClassrooms that shows the final score of 90%
A older version of a quiz on OpenClassrooms

Let's consider a real-life example of a feature that you probably know - the quiz on OpenClassrooms!

The Art of Writing User Stories

Composing user stories is not an exact science. Two people may write them very differently, without either being wrong.

Instead, it is an art. And the art of writing effective user stories develops with practice. There really is no substitute.

Even right now, with what you have learned in the last couple of lessons, you could get a blank piece of paper and try to write down the user stories for:

  • The Facebook Like feature.

  • Making a bid on an eBay listing.

  • A feature of your favorite product.

There is no shortcut for practice. If you stop reading now and spend 30 minutes writing down the user stories for any feature in any product - you will learn more than you ever will from reading.

An artist in front of an easel painting on a user story index card
Writing user stories is an art!

Practice "Hacking" User Stories

If my product needs a new search feature, I will look at other respected sites with the functionality and write down the user stories.

It might sound a bit crazy, but I'm not necessarily going to build the same user stories and product as my competitor. Instead, I simply want to understand the logic they used. And then I'll at least be aware of some of the logic, flow, and decisions they made.

The next time you have a specification to write, ask yourself who has done it well and use their product. Write the user stories out as you do so. It will improve your art!

A person in a hoodie sitting in front of a laptop
"Hacking" user stories just means writing user stories of competitor products!

The OpenClassrooms Quiz: Creating a Full Set of User Stories

The following sections will examine creating the user stories for the OpenClassrooms quiz adopting the following process to generate them:

  1. Write down the very high-level logic of a quiz.

  2. Write down a brief description of how users will interact with the quiz chronologically.

  3. Bullet point the main interactions chronologically.

  4. Translate those bullets into user stories. 

asd

Here are some general rules/logic of quizzes:

  • A teacher will create a quiz. 

  • A student will take the quiz. 

  • A quiz can have any number of questions (e.g., 3, 5, or 10). 

  • Questions can have a single correct answer (single choice) or many correct answers (multi-choice).

  • When students submit their answers, they see a results page showing the correct answers, explanations, and their score. 

  • A 70% score is required to pass a quiz. 

  • If a student fails, they can retake the quiz in 24 hours.

  • If they fail the quiz twice, they cannot retake it.

  • The teacher can work on the quiz and publish it when ready. 

ads

Think about the two user roles (teacher who creates the quiz and student who takes the quiz). The main interactions chronologically would be:

  1. First, the teacher creates a quiz.

  2. Then, the teacher adds questions and other details.

  3. Afterward, the teacher publishes the quiz.

  4. Next, the registered student can see the quiz and begin it.

  5. When the student submits the quiz, they see the results.

  6. Implement certain logic such as showing successful pass/fail messages, letting the student repeat the quiz, etc., based on whether they pass or fail.  

sd

This is similar to step 2 above, but in more detail.

Create a Quiz

To create a quiz, the teacher will:

  • Click on "create new quiz," which will open the "Create Quiz" page.

  • Add a question (the question, possible answers, correct answers, and explanation).

  •  Save the quiz and return later to continue working on it (if necessary).

  • Publish it when it is ready. 

Attempt the Quiz

The student will do the following in order:

  • Click on a quiz.

  • Arrive on the quiz page.

  • Enter their answers and submit the quiz.

  • See the results page.

Create a Pass/Fail Logic

And then think about the results and the impact of pass/fail:

  • If a student has a score of at least 70%, then they pass the quiz.

  • Next, they see a results page instead of a quiz page.

  • If the student fails the quiz, they can retake it in 24 hours.

  • If they fail a quiz twice, then they can no longer attempt it. They also cannot get a certificate of completion.

sd

Now lets create the user stories for the OpenClassroom quiz. Remember, user stories should be written in the following format:

an index card that reads :as a type of user I want some goal so that some reason
The user story format

 Create a Quiz (Teacher)

  • As a teacher, I want to create a quiz page so that I can add questions and save them without publishing.

  • As a teacher, I want to specify the question, possible answers, correct answers, and explanation,

  • As a teacher, I want to see an error message if a question does not have correct answers so that I can easily see if I've forgotten to specify them.

  • As a teacher, I want to choose between questions that have a single correct answer and multiple correct answers in order to test my students' knowledge when there is more than one correct answer.

  • As a teacher, I want to publish the quiz only once it is fully created so that it only appears to students when it is ready.

Attempt the Quiz (Student)

  • As a student, I want to open the quiz page when I click on a quiz in a course that I have registered for so that I can see the questions I have to answer.

  • As a student, I want to choose answers and submit the quiz so that I can test my understanding.

  • As a student, I want to see my results after I submit so that I can verify whether my knowledge was good enough to pass.

  • As a student, I want to see explanations for all questions, including an indication of ideal answers beside every question so that I can learn from the questions I got wrong.

Create a Pass/Fail Logic

  • As a student who has passed the test, I want to see my results if I revisit the quiz page later in order to check my score and to avoid attempting a quiz that I have already passed.

  • As a student who has failed the test, I want to retake this quiz 24 hours later.

  • As a student who has failed the test twice, I should be prevented from taking the quiz more than twice so that I'm required to really pay attention to the course and the quiz (rather than submitting many times without thinking).

  • As a student who passes all tests and activities, I should get a course certificate so that my achievements are recognized.

  • As a student who fails the course twice, I should not get a course certificate because I haven't demonstrated sufficient knowledge of the material.  

I just created 15 user stories for the OpenClassrooms Quiz!

Hopefully, you followed the process and understood what I did. Of course, you need to practice to do a similar job. So feel free to hack your favorite product’s user stories right now!

Let’s Recap!

  • User stories are steps towards increasing the value of your product. Consider who your users are, how they will use your product, and their common needs.

  • Create pass/fail scenarios so that you can account for positive and negative use cases in your product design.

  • Having a solid backlog of user stories will help you decide what you should build, when you should build it, and when you should release it.

Now that we have explored a user story in detail, let’s head to the next chapter, where we will look at acceptance tests. 

Example of certificate of achievement
Example of certificate of achievement