0
JavaScript Unit Testing Hanoi PHP Day 2010 @hoatle
JavaScript Unit Testing Framework <ul><li>Presenter: Hoat Le Van (aka hoatle) </li></ul><ul><li>eXo Social Team Leader </l...
Agenda <ul><li>JavaScript </li></ul><ul><li>Unit Testing </li></ul><ul><li>JavaScript Unit Testing Frameworks </li></ul><u...
JavaScript
What is JavaScript? <ul><li>An implementation of the ECMAScript language standard </li></ul><ul><li>The King of client-sid...
Unit Testing
What is Unit Testing? <ul><li>Units of source code are tested  </li></ul><ul><li>Written and run by developers to ensure t...
Samples (Java - JUnit)
Samples (Java - JUnit)
Samples (JavaScript - QUnit)
Samples (JavaScript - QUnit)
Test Driven Development (TDD) <ul><li>Writes a failing automated test case that defines a desired improvement or new funct...
Test Driven Development (TDD) (wikipedia)
Unit Testing Benefits <ul><li>To isolate each part of the program and show that the individual parts are correct </li></ul...
JavaScript Unit Testing Frameworks
JavaScript Unit Testing Frameworks
Fun time for JavaScript Unit Testing and Q&A?
Upcoming SlideShare
Loading in...5
×

Javascript unit testing framework

1,732

Published on

0 Comments
3 Likes
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total Views
1,732
On Slideshare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
17
Comments
0
Likes
3
Embeds 0
No embeds

No notes for slide

Transcript of "Javascript unit testing framework"

  1. 1. JavaScript Unit Testing Hanoi PHP Day 2010 @hoatle
  2. 2. JavaScript Unit Testing Framework <ul><li>Presenter: Hoat Le Van (aka hoatle) </li></ul><ul><li>eXo Social Team Leader </li></ul><ul><li>Hanoi PHP Day: </li></ul><ul><ul><li>2008: attendee </li></ul></ul><ul><ul><li>2009: Advanced JavaScript Techniques </li></ul></ul><ul><ul><li>2010: JavaScript Unit Testing Framework </li></ul></ul><ul><li>Work mostly with Java but have much interest in JavaScript </li></ul><ul><li>Twitter: @hoatle </li></ul>
  3. 3. Agenda <ul><li>JavaScript </li></ul><ul><li>Unit Testing </li></ul><ul><li>JavaScript Unit Testing Frameworks </li></ul><ul><li>Fun time for coding </li></ul>
  4. 4. JavaScript
  5. 5. What is JavaScript? <ul><li>An implementation of the ECMAScript language standard </li></ul><ul><li>The King of client-side scripting for web </li></ul><ul><li>A prototype-based object-oriented scripting language </li></ul><ul><li>“ The world's most misunderstood programming language” (Douglas Crockford) </li></ul><ul><ul><li>The Name </li></ul></ul><ul><ul><li>Bad books </li></ul></ul><ul><ul><li>Amateurs </li></ul></ul><ul><ul><li>Object Oriented? </li></ul></ul>
  6. 6. Unit Testing
  7. 7. What is Unit Testing? <ul><li>Units of source code are tested </li></ul><ul><li>Written and run by developers to ensure that code meets its design and behaves as intended and expected </li></ul><ul><li>Commonly automated </li></ul><ul><li>Extreme Programming uses the creation of unit tests for test-driven development </li></ul>
  8. 8. Samples (Java - JUnit)
  9. 9. Samples (Java - JUnit)
  10. 10. Samples (JavaScript - QUnit)
  11. 11. Samples (JavaScript - QUnit)
  12. 12. Test Driven Development (TDD) <ul><li>Writes a failing automated test case that defines a desired improvement or new function </li></ul><ul><li>Implements code to pass that test </li></ul><ul><li>Finally refactors </li></ul>
  13. 13. Test Driven Development (TDD) (wikipedia)
  14. 14. Unit Testing Benefits <ul><li>To isolate each part of the program and show that the individual parts are correct </li></ul><ul><li>Facilitates change </li></ul><ul><li>Documentation </li></ul><ul><li>Design </li></ul>
  15. 15. JavaScript Unit Testing Frameworks
  16. 16. JavaScript Unit Testing Frameworks
  17. 17. Fun time for JavaScript Unit Testing and Q&A?
  1. A particular slide catching your eye?

    Clipping is a handy way to collect important slides you want to go back to later.

×