Demo tests unitaires
Avec Karma et Jasmine
SPOILER
I’m not the biggest fan of unit tests !!!
Framework de tests unitaires Javascript
Jasmine
● Pretty old! It was created in 2010
(https://github.com/jasmine/jasmine/wiki/Background)
● It doesn’t require a DOM
● It is dependency free
● It is a behavior-driven development framework
switching costs between testing frameworks is relatively low with differences in syntax
as small as Jasmine's toEqual()and Mocha's to.equal().
GOOD NEWS
Test runner
Karma
● Created by the team behind Angular
● It runs on Node
● It can run your tests on various browsers and devices
● It integrates easily with various continuous integration services (Jenkins, etc)
Headless browser
PhantomJS
● Is is a web browser without a graphical user interface
● It can run on headless computers (without monitor)
● Based on WebKit making it a similar browsing environment as Safari, Opera,
etc
Demo tests unitaires karma jasmine - strasbourg js - decembre 2016

Demo tests unitaires karma jasmine - strasbourg js - decembre 2016

  • 1.
    Demo tests unitaires AvecKarma et Jasmine
  • 2.
    SPOILER I’m not thebiggest fan of unit tests !!!
  • 4.
    Framework de testsunitaires Javascript
  • 5.
    Jasmine ● Pretty old!It was created in 2010 (https://github.com/jasmine/jasmine/wiki/Background) ● It doesn’t require a DOM ● It is dependency free ● It is a behavior-driven development framework switching costs between testing frameworks is relatively low with differences in syntax as small as Jasmine's toEqual()and Mocha's to.equal(). GOOD NEWS
  • 6.
  • 7.
    Karma ● Created bythe team behind Angular ● It runs on Node ● It can run your tests on various browsers and devices ● It integrates easily with various continuous integration services (Jenkins, etc)
  • 8.
  • 9.
    PhantomJS ● Is isa web browser without a graphical user interface ● It can run on headless computers (without monitor) ● Based on WebKit making it a similar browsing environment as Safari, Opera, etc