SlideShare a Scribd company logo
Test-Driven Development
with TypeScript+Jasmine
+AngularJS
1
#smartorgdev
Somik Raha Kai Wu
Github repo: https://github.com/behappyrightnow/anagram
Thilak Selvan
2
A Brief History of Software
Engineering
ENIAC, 1946-55
3
Programs were input with Punched Cards
Human labor was cheap. Computer time was expensive.
More value in getting program right the first time.
4
IBM 360 Mainframes
Time-sharing computers
Late 1960s
Waterfall is a result of human
confusion
5
“Managing the Development of Large Software Systems”, Dr.
Winston W. Royce (Link) - 1970
6
For some mysterious reason, people latched
on to Fig 2, and thought it looked like a
waterfall.
The name caught up and ushered in
“phased” mindset of development.
7
But Dr. Royce had a Fig. 3
8
And a Fig. 4! As far back as 1970, Royce
was describing the
beginnings of an agile
mindset, but the Waterfall
religion had already
started, based on a
misunderstanding!
Meanwhile, a community of philosophers in
software engineering started forming in the
90’s
9
Ward Cunningham
Founding of the WikiWikiWeb in 1994.
Ward’s wiki became the home for
conversations on Design Patterns.
10
1995, caused a revolution in

Object-Oriented thinking
Book knows as the
“Gang of Four”
The false religion of Waterfall was then seriously
challenged in 2000
11
12
Source: agileatlas.org
Barry Boehm’s Cost of Change Curve
We were initially justified in doing high-quality design when
computer time was more expensive than programmer time
13
Aspirational Cost of Change curve
But now, programmer time is much more expensive, and we
would love to flatten the curve
time
costofchange
This is what Extreme Programming
was inviting us to consider
The XP Practices
14
The “Planning Game” had
strong influences from Scrum
What’s the difference?
Test-Driven Development
versus
Unit Testing
15
XP’s success led to a broader umbrella under a
more neutral-sounding “Agile Software
Development”
16
Core practices like TDD and Refactoring are no longer
controversial - they are a part of a programmer’s foundation.
Martin Fowler’s book is now a classic.
Most conventional IDEs support automated
refactoring.
17
Erich Gamma
One of the Gang of Four, authored
JUnit with Kent Beck, while on a long flight together,
1997
Great Article by Alberto Savoia: Beautiful Tests
History of xUnit by Martin Fowler
“JUnit took off like a rocket - and was essential to supporting
the growing movement of Extreme Programming and Test
Driven Development. I've seen a huge change of attitude
towards testing in the last decade, and I think JUnit played a
big role in that. By being small and simple it encouraged
people to learn and use it. It also proved amenable to others
extending it integrating it into tools.” — Martin Fowler
Lots of JUnit ports, generally
referred to as xUnit
18
nUnit - C#
cppUnit - C++
pyunit- Python
Functional Programming/
Behavior-Driven Development
19
Jasmine: TDD with JS from Pivotal Labs
Lettuce: DSL for testing and beyond by Gabriel Falcao
Continuous Build Servers
20
21
Let’s experience some TDD now
22
23
Anagram Unjumbler
leppa
zizap
couisldei
Unjumble this
We will use TypeScript
24
Anders Hejlsberg
Creator of C# and
TypeScript
Superset of Javascript
Supports class-based OO concepts
Takes the tedium out of JS
Keeps you in JS paradigm
(as opposed to coffee script)
We will use Testem
25
Continuously runs our unit tests
Step 1. git clone https://github.com/behappyrightnow/anagram.git
Step 2. cd anagram
Step 3. git checkout step1
Step 4. Install NodeJS from http://nodejs.org/
Step 5. npm install testem
Let’s start with checking out a basic stub from
Github
26
Let’s start by writing tests
27
Come up with 5 English words, jumble them up
Find all other words you can create with those letters
List your tests.
e.g.
INPUT OUTPUT
leppa apple
rodo door, odor
Challenge for you
28
Make the following game using existing codebase to help
game show hosts construct a puzzle.
Given an input word, create clues by adding one extra letter.
INPUT OUTPUT
rose horse without “h”
sores without “s”
Game show host can now use this program to construct
their show saying:
Can you find flowers using this clue…
Your web-interface should provide this:
PASS 1: Write the code without any tests
PASS 2: Keep your code aside, write tests first and then write code
Reflection: Write an essay on what you learned by comparing Pass 1 and
Pass 2, and in general what you learned from this session
Crack this challenge in the following way:
29

More Related Content

What's hot (20)

Releaseflow: a healthy build and deploy process
Releaseflow: a healthy build and deploy processReleaseflow: a healthy build and deploy process
Releaseflow: a healthy build and deploy process
Christopher Cundill
 
Let's Contribute
Let's ContributeLet's Contribute
Let's Contribute
Anoop Thomas Mathew
 
Working with c++ legacy code
Working with c++ legacy codeWorking with c++ legacy code
Working with c++ legacy code
Dror Helper
 
DevOpsDaysRiga 2018: Neil Crawford - Trunk based development, continuous depl...
DevOpsDaysRiga 2018: Neil Crawford - Trunk based development, continuous depl...DevOpsDaysRiga 2018: Neil Crawford - Trunk based development, continuous depl...
DevOpsDaysRiga 2018: Neil Crawford - Trunk based development, continuous depl...
DevOpsDays Riga
 
ATO 2014 - So You Think You Know 'Go'? The Go Programming Language
ATO 2014 - So You Think You Know 'Go'? The Go Programming LanguageATO 2014 - So You Think You Know 'Go'? The Go Programming Language
ATO 2014 - So You Think You Know 'Go'? The Go Programming Language
John Potocny
 
Kshitij
KshitijKshitij
Kshitij
Neelkanth Institute of Technology Meerut
 
Developer Job in Practice
Developer Job in PracticeDeveloper Job in Practice
Developer Job in Practice
intive
 
Let's Go @ St. Louis CocoaHeads
Let's Go @ St. Louis CocoaHeadsLet's Go @ St. Louis CocoaHeads
Let's Go @ St. Louis CocoaHeads
Paul Balogh
 
Develop Maintainable Apps - edUiConf
Develop Maintainable Apps - edUiConfDevelop Maintainable Apps - edUiConf
Develop Maintainable Apps - edUiConf
Annyce Davis
 
Improving Code Quality In Medical Software Through Code Reviews - Vincit Teat...
Improving Code Quality In Medical Software Through Code Reviews - Vincit Teat...Improving Code Quality In Medical Software Through Code Reviews - Vincit Teat...
Improving Code Quality In Medical Software Through Code Reviews - Vincit Teat...
VincitOy
 
JAZOON'13 - Andres Almiray - Spock: boldly go where no test has gone before
JAZOON'13 - Andres Almiray - Spock: boldly go where no test has gone beforeJAZOON'13 - Andres Almiray - Spock: boldly go where no test has gone before
JAZOON'13 - Andres Almiray - Spock: boldly go where no test has gone before
jazoon13
 
Git essentials
Git essentialsGit essentials
Git essentials
Otto Kekäläinen
 
Driving development in PHP
Driving development in PHPDriving development in PHP
Driving development in PHP
Eduardo Gulias Davis
 
Creating a reasonable project boilerplate
Creating a reasonable project boilerplateCreating a reasonable project boilerplate
Creating a reasonable project boilerplate
Stanislav Petrov
 
TDD with RSpec
TDD with RSpecTDD with RSpec
TDD with RSpec
Rachid Calazans
 
C++ in our world
C++ in our worldC++ in our world
C++ in our world
Juraj Michálek
 
CI/CD with OCP
CI/CD with OCPCI/CD with OCP
CI/CD with OCP
Dmitry Kartsev
 
OpenAPI and gRPC Side by-Side
OpenAPI and gRPC Side by-SideOpenAPI and gRPC Side by-Side
OpenAPI and gRPC Side by-Side
Tim Burks
 
Continuous Delivery for Python Developers – PyCon Otto
Continuous Delivery for Python Developers – PyCon OttoContinuous Delivery for Python Developers – PyCon Otto
Continuous Delivery for Python Developers – PyCon Otto
Peter Bittner
 
Test Driven Development with PHP
Test Driven Development with PHPTest Driven Development with PHP
Test Driven Development with PHP
Rogério Vicente
 
Releaseflow: a healthy build and deploy process
Releaseflow: a healthy build and deploy processReleaseflow: a healthy build and deploy process
Releaseflow: a healthy build and deploy process
Christopher Cundill
 
Working with c++ legacy code
Working with c++ legacy codeWorking with c++ legacy code
Working with c++ legacy code
Dror Helper
 
DevOpsDaysRiga 2018: Neil Crawford - Trunk based development, continuous depl...
DevOpsDaysRiga 2018: Neil Crawford - Trunk based development, continuous depl...DevOpsDaysRiga 2018: Neil Crawford - Trunk based development, continuous depl...
DevOpsDaysRiga 2018: Neil Crawford - Trunk based development, continuous depl...
DevOpsDays Riga
 
ATO 2014 - So You Think You Know 'Go'? The Go Programming Language
ATO 2014 - So You Think You Know 'Go'? The Go Programming LanguageATO 2014 - So You Think You Know 'Go'? The Go Programming Language
ATO 2014 - So You Think You Know 'Go'? The Go Programming Language
John Potocny
 
Developer Job in Practice
Developer Job in PracticeDeveloper Job in Practice
Developer Job in Practice
intive
 
Let's Go @ St. Louis CocoaHeads
Let's Go @ St. Louis CocoaHeadsLet's Go @ St. Louis CocoaHeads
Let's Go @ St. Louis CocoaHeads
Paul Balogh
 
Develop Maintainable Apps - edUiConf
Develop Maintainable Apps - edUiConfDevelop Maintainable Apps - edUiConf
Develop Maintainable Apps - edUiConf
Annyce Davis
 
Improving Code Quality In Medical Software Through Code Reviews - Vincit Teat...
Improving Code Quality In Medical Software Through Code Reviews - Vincit Teat...Improving Code Quality In Medical Software Through Code Reviews - Vincit Teat...
Improving Code Quality In Medical Software Through Code Reviews - Vincit Teat...
VincitOy
 
JAZOON'13 - Andres Almiray - Spock: boldly go where no test has gone before
JAZOON'13 - Andres Almiray - Spock: boldly go where no test has gone beforeJAZOON'13 - Andres Almiray - Spock: boldly go where no test has gone before
JAZOON'13 - Andres Almiray - Spock: boldly go where no test has gone before
jazoon13
 
Creating a reasonable project boilerplate
Creating a reasonable project boilerplateCreating a reasonable project boilerplate
Creating a reasonable project boilerplate
Stanislav Petrov
 
OpenAPI and gRPC Side by-Side
OpenAPI and gRPC Side by-SideOpenAPI and gRPC Side by-Side
OpenAPI and gRPC Side by-Side
Tim Burks
 
Continuous Delivery for Python Developers – PyCon Otto
Continuous Delivery for Python Developers – PyCon OttoContinuous Delivery for Python Developers – PyCon Otto
Continuous Delivery for Python Developers – PyCon Otto
Peter Bittner
 
Test Driven Development with PHP
Test Driven Development with PHPTest Driven Development with PHP
Test Driven Development with PHP
Rogério Vicente
 

Similar to Test-Driven Development with TypeScript+Jasmine+AngularJS (20)

Coding Naked
Coding NakedCoding Naked
Coding Naked
Caleb Jenkins
 
Driving application development through behavior driven development
Driving application development through behavior driven developmentDriving application development through behavior driven development
Driving application development through behavior driven development
Einar Ingebrigtsen
 
Unit Testing and TDD 2017
Unit Testing and TDD 2017Unit Testing and TDD 2017
Unit Testing and TDD 2017
Xavi Hidalgo
 
ES3-2020-05 Testing
ES3-2020-05 TestingES3-2020-05 Testing
ES3-2020-05 Testing
David Rodenas
 
Unit testing (eng)
Unit testing (eng)Unit testing (eng)
Unit testing (eng)
Anatoliy Okhotnikov
 
XP through TDD
XP through TDDXP through TDD
XP through TDD
Mauricio Cappella
 
TDD - Seriously, try it! - Opensouthcode
TDD - Seriously, try it! - OpensouthcodeTDD - Seriously, try it! - Opensouthcode
TDD - Seriously, try it! - Opensouthcode
Nacho Cougil
 
Testing 101
Testing 101Testing 101
Testing 101
Noam Barkai
 
Test Driven Development With YUI Test (Ajax Experience 2008)
Test Driven Development With YUI Test (Ajax Experience 2008)Test Driven Development With YUI Test (Ajax Experience 2008)
Test Driven Development With YUI Test (Ajax Experience 2008)
Nicholas Zakas
 
Automated testing overview
Automated testing overviewAutomated testing overview
Automated testing overview
Alex Pop
 
(automatic) Testing: from business to university and back
(automatic) Testing: from business to university and back(automatic) Testing: from business to university and back
(automatic) Testing: from business to university and back
David Rodenas
 
Agile Testing
Agile Testing  Agile Testing
Agile Testing
Intelliware Development Inc.
 
Agile Testing - What is it?
Agile Testing - What is it?Agile Testing - What is it?
Agile Testing - What is it?
Intelliware Development Inc.
 
Introduction to Automated Testing
Introduction to Automated TestingIntroduction to Automated Testing
Introduction to Automated Testing
Lars Thorup
 
Introduction to-automated-testing
Introduction to-automated-testingIntroduction to-automated-testing
Introduction to-automated-testing
BestBrains
 
Test-Driven Developments are Inefficient; Behavior-Driven Developments are a ...
Test-Driven Developments are Inefficient; Behavior-Driven Developments are a ...Test-Driven Developments are Inefficient; Behavior-Driven Developments are a ...
Test-Driven Developments are Inefficient; Behavior-Driven Developments are a ...
Abdelkrim Boujraf
 
Test driven development
Test driven developmentTest driven development
Test driven development
Dennis Ahaus
 
Test and Behaviour Driven Development (TDD/BDD)
Test and Behaviour Driven Development (TDD/BDD)Test and Behaviour Driven Development (TDD/BDD)
Test and Behaviour Driven Development (TDD/BDD)
Lars Thorup
 
TDD - Christchurch APN May 2012
TDD - Christchurch APN May 2012TDD - Christchurch APN May 2012
TDD - Christchurch APN May 2012
Alan Christensen
 
Effective TDD - Less is more
Effective TDD - Less is moreEffective TDD - Less is more
Effective TDD - Less is more
Ben Lau
 
Driving application development through behavior driven development
Driving application development through behavior driven developmentDriving application development through behavior driven development
Driving application development through behavior driven development
Einar Ingebrigtsen
 
Unit Testing and TDD 2017
Unit Testing and TDD 2017Unit Testing and TDD 2017
Unit Testing and TDD 2017
Xavi Hidalgo
 
TDD - Seriously, try it! - Opensouthcode
TDD - Seriously, try it! - OpensouthcodeTDD - Seriously, try it! - Opensouthcode
TDD - Seriously, try it! - Opensouthcode
Nacho Cougil
 
Test Driven Development With YUI Test (Ajax Experience 2008)
Test Driven Development With YUI Test (Ajax Experience 2008)Test Driven Development With YUI Test (Ajax Experience 2008)
Test Driven Development With YUI Test (Ajax Experience 2008)
Nicholas Zakas
 
Automated testing overview
Automated testing overviewAutomated testing overview
Automated testing overview
Alex Pop
 
(automatic) Testing: from business to university and back
(automatic) Testing: from business to university and back(automatic) Testing: from business to university and back
(automatic) Testing: from business to university and back
David Rodenas
 
Introduction to Automated Testing
Introduction to Automated TestingIntroduction to Automated Testing
Introduction to Automated Testing
Lars Thorup
 
Introduction to-automated-testing
Introduction to-automated-testingIntroduction to-automated-testing
Introduction to-automated-testing
BestBrains
 
Test-Driven Developments are Inefficient; Behavior-Driven Developments are a ...
Test-Driven Developments are Inefficient; Behavior-Driven Developments are a ...Test-Driven Developments are Inefficient; Behavior-Driven Developments are a ...
Test-Driven Developments are Inefficient; Behavior-Driven Developments are a ...
Abdelkrim Boujraf
 
Test driven development
Test driven developmentTest driven development
Test driven development
Dennis Ahaus
 
Test and Behaviour Driven Development (TDD/BDD)
Test and Behaviour Driven Development (TDD/BDD)Test and Behaviour Driven Development (TDD/BDD)
Test and Behaviour Driven Development (TDD/BDD)
Lars Thorup
 
TDD - Christchurch APN May 2012
TDD - Christchurch APN May 2012TDD - Christchurch APN May 2012
TDD - Christchurch APN May 2012
Alan Christensen
 
Effective TDD - Less is more
Effective TDD - Less is moreEffective TDD - Less is more
Effective TDD - Less is more
Ben Lau
 
Ad

More from SmartOrg (18)

FEI Digital Week Webinar at Innovation Management - October 2019
FEI Digital Week Webinar at Innovation Management - October 2019 FEI Digital Week Webinar at Innovation Management - October 2019
FEI Digital Week Webinar at Innovation Management - October 2019
SmartOrg
 
Comic Book: Adventures in Product Innovation
Comic Book: Adventures in Product InnovationComic Book: Adventures in Product Innovation
Comic Book: Adventures in Product Innovation
SmartOrg
 
Head and Heart in Decision Quality
Head and Heart in Decision QualityHead and Heart in Decision Quality
Head and Heart in Decision Quality
SmartOrg
 
Embedded DA vs Consultative DA: Audience Workshop
Embedded DA vs Consultative DA: Audience WorkshopEmbedded DA vs Consultative DA: Audience Workshop
Embedded DA vs Consultative DA: Audience Workshop
SmartOrg
 
Embedded Decision Analysis: Systems Design Patterns
Embedded Decision Analysis: Systems Design PatternsEmbedded Decision Analysis: Systems Design Patterns
Embedded Decision Analysis: Systems Design Patterns
SmartOrg
 
Design strategies for AngularJS
Design strategies for AngularJSDesign strategies for AngularJS
Design strategies for AngularJS
SmartOrg
 
Stanford-SDG Webinar Six critical principles of strategic portfolio management
Stanford-SDG Webinar Six critical principles of strategic portfolio managementStanford-SDG Webinar Six critical principles of strategic portfolio management
Stanford-SDG Webinar Six critical principles of strategic portfolio management
SmartOrg
 
Experimenting with Values
Experimenting with ValuesExperimenting with Values
Experimenting with Values
SmartOrg
 
Portfolio management 101
Portfolio management 101Portfolio management 101
Portfolio management 101
SmartOrg
 
Embedded Decision Analysis
Embedded Decision AnalysisEmbedded Decision Analysis
Embedded Decision Analysis
SmartOrg
 
Failing forward v2
Failing forward v2Failing forward v2
Failing forward v2
SmartOrg
 
Agile business development
Agile business developmentAgile business development
Agile business development
SmartOrg
 
Infographics GIL 2013 Silicon Valley
Infographics GIL 2013 Silicon ValleyInfographics GIL 2013 Silicon Valley
Infographics GIL 2013 Silicon Valley
SmartOrg
 
Accelerating the deployment of technology to business opportunities-chevron T...
Accelerating the deployment of technology to business opportunities-chevron T...Accelerating the deployment of technology to business opportunities-chevron T...
Accelerating the deployment of technology to business opportunities-chevron T...
SmartOrg
 
Principles of strategic portfolio management
Principles of strategic portfolio managementPrinciples of strategic portfolio management
Principles of strategic portfolio management
SmartOrg
 
Innovation story
Innovation storyInnovation story
Innovation story
SmartOrg
 
Agile business development
Agile business developmentAgile business development
Agile business development
SmartOrg
 
Framing Patterns
Framing PatternsFraming Patterns
Framing Patterns
SmartOrg
 
FEI Digital Week Webinar at Innovation Management - October 2019
FEI Digital Week Webinar at Innovation Management - October 2019 FEI Digital Week Webinar at Innovation Management - October 2019
FEI Digital Week Webinar at Innovation Management - October 2019
SmartOrg
 
Comic Book: Adventures in Product Innovation
Comic Book: Adventures in Product InnovationComic Book: Adventures in Product Innovation
Comic Book: Adventures in Product Innovation
SmartOrg
 
Head and Heart in Decision Quality
Head and Heart in Decision QualityHead and Heart in Decision Quality
Head and Heart in Decision Quality
SmartOrg
 
Embedded DA vs Consultative DA: Audience Workshop
Embedded DA vs Consultative DA: Audience WorkshopEmbedded DA vs Consultative DA: Audience Workshop
Embedded DA vs Consultative DA: Audience Workshop
SmartOrg
 
Embedded Decision Analysis: Systems Design Patterns
Embedded Decision Analysis: Systems Design PatternsEmbedded Decision Analysis: Systems Design Patterns
Embedded Decision Analysis: Systems Design Patterns
SmartOrg
 
Design strategies for AngularJS
Design strategies for AngularJSDesign strategies for AngularJS
Design strategies for AngularJS
SmartOrg
 
Stanford-SDG Webinar Six critical principles of strategic portfolio management
Stanford-SDG Webinar Six critical principles of strategic portfolio managementStanford-SDG Webinar Six critical principles of strategic portfolio management
Stanford-SDG Webinar Six critical principles of strategic portfolio management
SmartOrg
 
Experimenting with Values
Experimenting with ValuesExperimenting with Values
Experimenting with Values
SmartOrg
 
Portfolio management 101
Portfolio management 101Portfolio management 101
Portfolio management 101
SmartOrg
 
Embedded Decision Analysis
Embedded Decision AnalysisEmbedded Decision Analysis
Embedded Decision Analysis
SmartOrg
 
Failing forward v2
Failing forward v2Failing forward v2
Failing forward v2
SmartOrg
 
Agile business development
Agile business developmentAgile business development
Agile business development
SmartOrg
 
Infographics GIL 2013 Silicon Valley
Infographics GIL 2013 Silicon ValleyInfographics GIL 2013 Silicon Valley
Infographics GIL 2013 Silicon Valley
SmartOrg
 
Accelerating the deployment of technology to business opportunities-chevron T...
Accelerating the deployment of technology to business opportunities-chevron T...Accelerating the deployment of technology to business opportunities-chevron T...
Accelerating the deployment of technology to business opportunities-chevron T...
SmartOrg
 
Principles of strategic portfolio management
Principles of strategic portfolio managementPrinciples of strategic portfolio management
Principles of strategic portfolio management
SmartOrg
 
Innovation story
Innovation storyInnovation story
Innovation story
SmartOrg
 
Agile business development
Agile business developmentAgile business development
Agile business development
SmartOrg
 
Framing Patterns
Framing PatternsFraming Patterns
Framing Patterns
SmartOrg
 
Ad

Recently uploaded (20)

"Hymenoptera: A Diverse and Fascinating Order".pptx
"Hymenoptera: A Diverse and Fascinating Order".pptx"Hymenoptera: A Diverse and Fascinating Order".pptx
"Hymenoptera: A Diverse and Fascinating Order".pptx
Arshad Shaikh
 
IDSP(INTEGRATED DISEASE SURVEILLANCE PROGRAMME...
IDSP(INTEGRATED DISEASE SURVEILLANCE PROGRAMME...IDSP(INTEGRATED DISEASE SURVEILLANCE PROGRAMME...
IDSP(INTEGRATED DISEASE SURVEILLANCE PROGRAMME...
SweetytamannaMohapat
 
Exploring Identity Through Colombian Companies
Exploring Identity Through Colombian CompaniesExploring Identity Through Colombian Companies
Exploring Identity Through Colombian Companies
OlgaLeonorTorresSnch
 
Stewart Butler - OECD - How to design and deliver higher technical education ...
Stewart Butler - OECD - How to design and deliver higher technical education ...Stewart Butler - OECD - How to design and deliver higher technical education ...
Stewart Butler - OECD - How to design and deliver higher technical education ...
EduSkills OECD
 
প্রত্যুৎপন্নমতিত্ব - Prottutponnomotittwa 2025.pdf
প্রত্যুৎপন্নমতিত্ব - Prottutponnomotittwa 2025.pdfপ্রত্যুৎপন্নমতিত্ব - Prottutponnomotittwa 2025.pdf
প্রত্যুৎপন্নমতিত্ব - Prottutponnomotittwa 2025.pdf
Pragya - UEM Kolkata Quiz Club
 
How to Create Time Off Request in Odoo 18 Time Off
How to Create Time Off Request in Odoo 18 Time OffHow to Create Time Off Request in Odoo 18 Time Off
How to Create Time Off Request in Odoo 18 Time Off
Celine George
 
How to Use Owl Slots in Odoo 17 - Odoo Slides
How to Use Owl Slots in Odoo 17 - Odoo SlidesHow to Use Owl Slots in Odoo 17 - Odoo Slides
How to Use Owl Slots in Odoo 17 - Odoo Slides
Celine George
 
Order Lepidoptera: Butterflies and Moths.pptx
Order Lepidoptera: Butterflies and Moths.pptxOrder Lepidoptera: Butterflies and Moths.pptx
Order Lepidoptera: Butterflies and Moths.pptx
Arshad Shaikh
 
TechSoup Microsoft Copilot Nonprofit Use Cases and Live Demo - 2025.05.28.pdf
TechSoup Microsoft Copilot Nonprofit Use Cases and Live Demo - 2025.05.28.pdfTechSoup Microsoft Copilot Nonprofit Use Cases and Live Demo - 2025.05.28.pdf
TechSoup Microsoft Copilot Nonprofit Use Cases and Live Demo - 2025.05.28.pdf
TechSoup
 
LDMMIA About me 2025 Edition 3 College Volume
LDMMIA About me 2025 Edition 3 College VolumeLDMMIA About me 2025 Edition 3 College Volume
LDMMIA About me 2025 Edition 3 College Volume
LDM & Mia eStudios
 
STUDENT LOAN TRUST FUND DEFAULTERS GHANA
STUDENT LOAN TRUST FUND DEFAULTERS GHANASTUDENT LOAN TRUST FUND DEFAULTERS GHANA
STUDENT LOAN TRUST FUND DEFAULTERS GHANA
Kweku Zurek
 
Introduction to Online CME for Nurse Practitioners.pdf
Introduction to Online CME for Nurse Practitioners.pdfIntroduction to Online CME for Nurse Practitioners.pdf
Introduction to Online CME for Nurse Practitioners.pdf
CME4Life
 
Critical Thinking and Bias with Jibi Moses
Critical Thinking and Bias with Jibi MosesCritical Thinking and Bias with Jibi Moses
Critical Thinking and Bias with Jibi Moses
Excellence Foundation for South Sudan
 
LDMMIA Free Reiki Yoga S7 Weekly Workshops
LDMMIA Free Reiki Yoga S7 Weekly WorkshopsLDMMIA Free Reiki Yoga S7 Weekly Workshops
LDMMIA Free Reiki Yoga S7 Weekly Workshops
LDM & Mia eStudios
 
How to Setup Renewal of Subscription in Odoo 18
How to Setup Renewal of Subscription in Odoo 18How to Setup Renewal of Subscription in Odoo 18
How to Setup Renewal of Subscription in Odoo 18
Celine George
 
State institute of educational technology
State institute of educational technologyState institute of educational technology
State institute of educational technology
vp5806484
 
0b - THE ROMANTIC ERA: FEELINGS AND IDENTITY.pptx
0b - THE ROMANTIC ERA: FEELINGS AND IDENTITY.pptx0b - THE ROMANTIC ERA: FEELINGS AND IDENTITY.pptx
0b - THE ROMANTIC ERA: FEELINGS AND IDENTITY.pptx
Julián Jesús Pérez Fernández
 
Forestry Model Exit Exam_2025_Wollega University, Gimbi Campus.pdf
Forestry Model Exit Exam_2025_Wollega University, Gimbi Campus.pdfForestry Model Exit Exam_2025_Wollega University, Gimbi Campus.pdf
Forestry Model Exit Exam_2025_Wollega University, Gimbi Campus.pdf
ChalaKelbessa
 
Diana Enriquez Wauconda - A Wauconda-Based Educator
Diana Enriquez Wauconda - A Wauconda-Based EducatorDiana Enriquez Wauconda - A Wauconda-Based Educator
Diana Enriquez Wauconda - A Wauconda-Based Educator
Diana Enriquez Wauconda
 
Dashboard Overview in Odoo 18 - Odoo Slides
Dashboard Overview in Odoo 18 - Odoo SlidesDashboard Overview in Odoo 18 - Odoo Slides
Dashboard Overview in Odoo 18 - Odoo Slides
Celine George
 
"Hymenoptera: A Diverse and Fascinating Order".pptx
"Hymenoptera: A Diverse and Fascinating Order".pptx"Hymenoptera: A Diverse and Fascinating Order".pptx
"Hymenoptera: A Diverse and Fascinating Order".pptx
Arshad Shaikh
 
IDSP(INTEGRATED DISEASE SURVEILLANCE PROGRAMME...
IDSP(INTEGRATED DISEASE SURVEILLANCE PROGRAMME...IDSP(INTEGRATED DISEASE SURVEILLANCE PROGRAMME...
IDSP(INTEGRATED DISEASE SURVEILLANCE PROGRAMME...
SweetytamannaMohapat
 
Exploring Identity Through Colombian Companies
Exploring Identity Through Colombian CompaniesExploring Identity Through Colombian Companies
Exploring Identity Through Colombian Companies
OlgaLeonorTorresSnch
 
Stewart Butler - OECD - How to design and deliver higher technical education ...
Stewart Butler - OECD - How to design and deliver higher technical education ...Stewart Butler - OECD - How to design and deliver higher technical education ...
Stewart Butler - OECD - How to design and deliver higher technical education ...
EduSkills OECD
 
প্রত্যুৎপন্নমতিত্ব - Prottutponnomotittwa 2025.pdf
প্রত্যুৎপন্নমতিত্ব - Prottutponnomotittwa 2025.pdfপ্রত্যুৎপন্নমতিত্ব - Prottutponnomotittwa 2025.pdf
প্রত্যুৎপন্নমতিত্ব - Prottutponnomotittwa 2025.pdf
Pragya - UEM Kolkata Quiz Club
 
How to Create Time Off Request in Odoo 18 Time Off
How to Create Time Off Request in Odoo 18 Time OffHow to Create Time Off Request in Odoo 18 Time Off
How to Create Time Off Request in Odoo 18 Time Off
Celine George
 
How to Use Owl Slots in Odoo 17 - Odoo Slides
How to Use Owl Slots in Odoo 17 - Odoo SlidesHow to Use Owl Slots in Odoo 17 - Odoo Slides
How to Use Owl Slots in Odoo 17 - Odoo Slides
Celine George
 
Order Lepidoptera: Butterflies and Moths.pptx
Order Lepidoptera: Butterflies and Moths.pptxOrder Lepidoptera: Butterflies and Moths.pptx
Order Lepidoptera: Butterflies and Moths.pptx
Arshad Shaikh
 
TechSoup Microsoft Copilot Nonprofit Use Cases and Live Demo - 2025.05.28.pdf
TechSoup Microsoft Copilot Nonprofit Use Cases and Live Demo - 2025.05.28.pdfTechSoup Microsoft Copilot Nonprofit Use Cases and Live Demo - 2025.05.28.pdf
TechSoup Microsoft Copilot Nonprofit Use Cases and Live Demo - 2025.05.28.pdf
TechSoup
 
LDMMIA About me 2025 Edition 3 College Volume
LDMMIA About me 2025 Edition 3 College VolumeLDMMIA About me 2025 Edition 3 College Volume
LDMMIA About me 2025 Edition 3 College Volume
LDM & Mia eStudios
 
STUDENT LOAN TRUST FUND DEFAULTERS GHANA
STUDENT LOAN TRUST FUND DEFAULTERS GHANASTUDENT LOAN TRUST FUND DEFAULTERS GHANA
STUDENT LOAN TRUST FUND DEFAULTERS GHANA
Kweku Zurek
 
Introduction to Online CME for Nurse Practitioners.pdf
Introduction to Online CME for Nurse Practitioners.pdfIntroduction to Online CME for Nurse Practitioners.pdf
Introduction to Online CME for Nurse Practitioners.pdf
CME4Life
 
LDMMIA Free Reiki Yoga S7 Weekly Workshops
LDMMIA Free Reiki Yoga S7 Weekly WorkshopsLDMMIA Free Reiki Yoga S7 Weekly Workshops
LDMMIA Free Reiki Yoga S7 Weekly Workshops
LDM & Mia eStudios
 
How to Setup Renewal of Subscription in Odoo 18
How to Setup Renewal of Subscription in Odoo 18How to Setup Renewal of Subscription in Odoo 18
How to Setup Renewal of Subscription in Odoo 18
Celine George
 
State institute of educational technology
State institute of educational technologyState institute of educational technology
State institute of educational technology
vp5806484
 
Forestry Model Exit Exam_2025_Wollega University, Gimbi Campus.pdf
Forestry Model Exit Exam_2025_Wollega University, Gimbi Campus.pdfForestry Model Exit Exam_2025_Wollega University, Gimbi Campus.pdf
Forestry Model Exit Exam_2025_Wollega University, Gimbi Campus.pdf
ChalaKelbessa
 
Diana Enriquez Wauconda - A Wauconda-Based Educator
Diana Enriquez Wauconda - A Wauconda-Based EducatorDiana Enriquez Wauconda - A Wauconda-Based Educator
Diana Enriquez Wauconda - A Wauconda-Based Educator
Diana Enriquez Wauconda
 
Dashboard Overview in Odoo 18 - Odoo Slides
Dashboard Overview in Odoo 18 - Odoo SlidesDashboard Overview in Odoo 18 - Odoo Slides
Dashboard Overview in Odoo 18 - Odoo Slides
Celine George
 

Test-Driven Development with TypeScript+Jasmine+AngularJS

  • 1. Test-Driven Development with TypeScript+Jasmine +AngularJS 1 #smartorgdev Somik Raha Kai Wu Github repo: https://github.com/behappyrightnow/anagram Thilak Selvan
  • 2. 2 A Brief History of Software Engineering ENIAC, 1946-55
  • 3. 3 Programs were input with Punched Cards Human labor was cheap. Computer time was expensive. More value in getting program right the first time.
  • 4. 4 IBM 360 Mainframes Time-sharing computers Late 1960s
  • 5. Waterfall is a result of human confusion 5 “Managing the Development of Large Software Systems”, Dr. Winston W. Royce (Link) - 1970
  • 6. 6 For some mysterious reason, people latched on to Fig 2, and thought it looked like a waterfall. The name caught up and ushered in “phased” mindset of development.
  • 7. 7 But Dr. Royce had a Fig. 3
  • 8. 8 And a Fig. 4! As far back as 1970, Royce was describing the beginnings of an agile mindset, but the Waterfall religion had already started, based on a misunderstanding!
  • 9. Meanwhile, a community of philosophers in software engineering started forming in the 90’s 9 Ward Cunningham Founding of the WikiWikiWeb in 1994. Ward’s wiki became the home for conversations on Design Patterns.
  • 10. 10 1995, caused a revolution in
 Object-Oriented thinking Book knows as the “Gang of Four”
  • 11. The false religion of Waterfall was then seriously challenged in 2000 11
  • 12. 12 Source: agileatlas.org Barry Boehm’s Cost of Change Curve We were initially justified in doing high-quality design when computer time was more expensive than programmer time
  • 13. 13 Aspirational Cost of Change curve But now, programmer time is much more expensive, and we would love to flatten the curve time costofchange This is what Extreme Programming was inviting us to consider
  • 14. The XP Practices 14 The “Planning Game” had strong influences from Scrum
  • 15. What’s the difference? Test-Driven Development versus Unit Testing 15
  • 16. XP’s success led to a broader umbrella under a more neutral-sounding “Agile Software Development” 16 Core practices like TDD and Refactoring are no longer controversial - they are a part of a programmer’s foundation. Martin Fowler’s book is now a classic. Most conventional IDEs support automated refactoring.
  • 17. 17 Erich Gamma One of the Gang of Four, authored JUnit with Kent Beck, while on a long flight together, 1997 Great Article by Alberto Savoia: Beautiful Tests History of xUnit by Martin Fowler “JUnit took off like a rocket - and was essential to supporting the growing movement of Extreme Programming and Test Driven Development. I've seen a huge change of attitude towards testing in the last decade, and I think JUnit played a big role in that. By being small and simple it encouraged people to learn and use it. It also proved amenable to others extending it integrating it into tools.” — Martin Fowler
  • 18. Lots of JUnit ports, generally referred to as xUnit 18 nUnit - C# cppUnit - C++ pyunit- Python
  • 19. Functional Programming/ Behavior-Driven Development 19 Jasmine: TDD with JS from Pivotal Labs Lettuce: DSL for testing and beyond by Gabriel Falcao
  • 21. 21
  • 24. We will use TypeScript 24 Anders Hejlsberg Creator of C# and TypeScript Superset of Javascript Supports class-based OO concepts Takes the tedium out of JS Keeps you in JS paradigm (as opposed to coffee script)
  • 25. We will use Testem 25 Continuously runs our unit tests
  • 26. Step 1. git clone https://github.com/behappyrightnow/anagram.git Step 2. cd anagram Step 3. git checkout step1 Step 4. Install NodeJS from http://nodejs.org/ Step 5. npm install testem Let’s start with checking out a basic stub from Github 26
  • 27. Let’s start by writing tests 27 Come up with 5 English words, jumble them up Find all other words you can create with those letters List your tests. e.g. INPUT OUTPUT leppa apple rodo door, odor
  • 28. Challenge for you 28 Make the following game using existing codebase to help game show hosts construct a puzzle. Given an input word, create clues by adding one extra letter. INPUT OUTPUT rose horse without “h” sores without “s” Game show host can now use this program to construct their show saying: Can you find flowers using this clue… Your web-interface should provide this:
  • 29. PASS 1: Write the code without any tests PASS 2: Keep your code aside, write tests first and then write code Reflection: Write an essay on what you learned by comparing Pass 1 and Pass 2, and in general what you learned from this session Crack this challenge in the following way: 29