Write Tests Like a Mathematician: Part 2

Ember provides 3 types of tests out of the box:

  • Unit tests
  • Rendering tests (previously known as integration tests)
  • Application tests (previously known as acceptance tests)

Broadly speaking, these tests differ in two aspects:

  • Which parts of your app they check for correctness. Having different types of tests help separate testing concerns.
  • How fast they execute.

Let’s take a look at each type and when you might use one over another.

Continue reading “Write Tests Like a Mathematician: Part 2”

Write Tests Like a Mathematician: Part 1

Ember gives you the power to write tests and be productive from day one. You can be confident that your app will be correct today and years from now. A question remains: How should you write tests?

Since tests are a core part of the Ember framework and your development cycle, I will dedicate several blog posts on best practices for writing tests, based on my experience at work and former life as mathematician.

Today, we will cover why testing is important, what tools can help you with testing, and how to run and debug your tests.

Please note that some tools may be readily available for Ember only. However, the best practices that I will mention should be independent of your framework. After all, tests are a universal language, just like math is.

Continue reading “Write Tests Like a Mathematician: Part 1”