Part 1 - Test Master

Step 1 - Setup

  • os install function-master
  • open up test-master.html in your c9 and serve it.
  • open up test-master.js in your c9 and have a look.

Step 2 - Be The Test Master

test-master.js contains a bunch of unit tests. Unit tests help us verify that our code is doing the right thing by calling our functions with some test data and making sure that our functions do the right thing. These tests are incomplete and it is our job today to complete them.

  • Inspect the tests on the page and try to understand what's going on in general.
  • All the tests are currently failing.
  • If we look in test-master.html we can see that they are red and their status is failed
  • Each one of the tests has at least one occurrance of "???". This is what we need to change.
  • Change each "???" to the value that will make the test pass
  • Once they pass they will be blue and not red on the page!

Part 2 - Function Master

Step 1 - typeof

  • what can we typeof ?
  • what can't we typeof ?
  • how do we check those things?

Step 2 - The Standard Library

  • Object.keys()
  • String.toUpperCase
  • String.split
  • String.join
  • Array.join

Step 3 - Be The Function Master

  • If you don't understand what a function is supposed to do, look at the test. If you still don't understand, ask me.