SlideShare a Scribd company logo
1 of 60
Download to read offline
Test Continuous
Kang-min Liu <gugod@gugod.org>
Continuous Testing

http://groups.csail.mit.edu/pag/continuoustesting/
Eclipse Plugin
     For Java
JUnit
Foo.java
FooTest.java
Changed

Foo.java
FooTest.java
Changed

Foo.java
FooTest.java
                     auto run
HEY
We   Perl
Test::Continuous
http://search.cpan.org/dist/Test-Continuous
DEMO
perl -MTest::Continuous -e runtests'




              murmur: There should be a better way...
---------------------------------------------
/Users/gugod/dev/Acme-Greeting/t/01.english.t (Wstat: 65280 Tests: 5
Failed: 1)
 Failed test: 5
 Non-zero exit status: 255
 Parse errors: Bad plan. You planned 4 tests but ran 5.
Files=1, Tests=5, 0 wallclock secs ( 0.00 usr 0.01 sys + 0.05 cusr 0.01
csys = 0.07 CPU)
Result: FAIL
[MSG]: /Users/gugod/Acme-Greeting/t/01.english.t was changed.
/Users/gugod/dev/Acme-Greeting/t/01.english......ok

---------------------------------------------
Result: PASS
[MSG]: /Users/gugod/dev/Acme-Greeting/t/01.english.t was changed.
/Users/gugod/dev/Acme-Greeting/t/01.english......ok

---------------------------------------------
What It Does...
1. Scan modified files
2. Find all tests requiring a re-run.
3. Run those tests
4. Report PASS / FAIL
5. GOTO 1
How it’s done
1. Scan modified files. File::Modified
2. Find all tests requiring a re-run.
   Module::ExtractUse
3. Run those tests. App::Prove
4. Report PASS / FAIL. Log::Dispatch
5. GOTO 1. while(1)
CPANFTW
CPAN For The Win
Good For...
Test Driven
Development
Test Driven
Refactoring
<CODE>
What It Does (1st day)

1. Wait until any file is modified
2. Run all tests
3. Report PASS / FAIL
4. GOTO 1
Run ALL tests
Wasting Time
Write less test
bad software
hate software
Run as few tests
  as possible
   Module::ExtractUse
Only run .t if that’s
    modified
dependency of .t
Moose.pm   moose.t



Cow.pm      cow.t



 OX.pm      fight.t
Moose.pm   moose.t



Cow.pm      cow.t



 OX.pm      fight.t
Moose.pm   moose.t



Cow.pm      cow.t



 OX.pm      fight.t
Moose.pm   moose.t



Cow.pm      cow.t



 OX.pm      fight.t
Moose.pm   moose.t



Cow.pm      cow.t



 OX.pm      fight.t
Log::Dispatch based
    notification
    Should be easy extend
Log::Dispatch::Screen
---------------------------------------------
/Users/gugod/dev/Acme-Greeting/t/01.english.t (Wstat: 65280 Tests: 5
Failed: 1)
 Failed test: 5
 Non-zero exit status: 255
 Parse errors: Bad plan. You planned 4 tests but ran 5.
Files=1, Tests=5, 0 wallclock secs ( 0.00 usr 0.01 sys + 0.05 cusr 0.01
csys = 0.07 CPU)
Result: FAIL
[MSG]: /Users/gugod/Acme-Greeting/t/01.english.t was changed.
/Users/gugod/dev/Acme-Greeting/t/01.english......ok

---------------------------------------------
Result: PASS
[MSG]: /Users/gugod/dev/Acme-Greeting/t/01.english.t was changed.
/Users/gugod/dev/Acme-Greeting/t/01.english......ok

---------------------------------------------
/me   Mac
Good developing
   platform


       and macbook air is so shiny
Growl
                    Universal Reminder




http://growl.info
Growl
                    Universal Reminder




http://growl.info
Log::Disptach::MacGrowl
       auto-used if installed
Log::Disptach::MacGrowl
       auto-used if installed
Not good enough...
Only check .pm
 dependency
      .pm → .t
       .c → .t
     .conf → .t
     .yaml → .t
Shallow Dependency
Animal.pm           Moose.pm




Cow.pm      cow.t   moose.t
isa
Animal.pm            Moose.pm




Cow.pm       cow.t   moose.t
isa
Animal.pm            Moose.pm



 isa


Cow.pm       cow.t   moose.t
isa
Animal.pm            Moose.pm



 isa                     tested by


Cow.pm       cow.t   moose.t
isa
Animal.pm                     Moose.pm



 isa                              tested by
            tested
              by
Cow.pm                cow.t   moose.t
isa
Animal.pm                     Moose.pm



 isa                              tested by
            tested
              by
Cow.pm                cow.t   moose.t
isa
Animal.pm                         Moose.pm
               tested by

 isa                                  tested by
                       animal.t
            tested
              by
Cow.pm                cow.t       moose.t
Should clearly notified
    what’s failed
No High-Def cute
  looking icon
  ICON DESIGNER WANTED
Future
• Better Dependency Detection
 • Convention based (For Catalyst / Jifty /
    Others)
  • Configuration based
• Support other Universal Reminder on
  other platform. (Twitter!)
END
Happy Testing

More Related Content

Viewers also liked (7)

Equipos
EquiposEquipos
Equipos
 
razvijanje Indie iger
razvijanje Indie igerrazvijanje Indie iger
razvijanje Indie iger
 
Good Evils In Perl (Yapc Asia)
Good Evils In Perl (Yapc Asia)Good Evils In Perl (Yapc Asia)
Good Evils In Perl (Yapc Asia)
 
My Learning Experience
My Learning ExperienceMy Learning Experience
My Learning Experience
 
perlbrew yapcasia 2010
perlbrew yapcasia 2010perlbrew yapcasia 2010
perlbrew yapcasia 2010
 
Same but Different
Same but DifferentSame but Different
Same but Different
 
Turismo 2.0 Mallorca (BRECHA DIGITAL )
Turismo 2.0 Mallorca (BRECHA DIGITAL )Turismo 2.0 Mallorca (BRECHA DIGITAL )
Turismo 2.0 Mallorca (BRECHA DIGITAL )
 

Similar to Test Continuous

Django’s nasal passage
Django’s nasal passageDjango’s nasal passage
Django’s nasal passage
Erik Rose
 
Testing Salt States (part 1)
Testing Salt States (part 1)Testing Salt States (part 1)
Testing Salt States (part 1)
jasondenning
 

Similar to Test Continuous (20)

testing for people who hate testing
testing for people who hate testingtesting for people who hate testing
testing for people who hate testing
 
Don't Leave Windows Broken
Don't Leave Windows BrokenDon't Leave Windows Broken
Don't Leave Windows Broken
 
Beaker: Automated, Cloud-Based Acceptance Testing - PuppetConf 2014
Beaker: Automated, Cloud-Based Acceptance Testing - PuppetConf 2014Beaker: Automated, Cloud-Based Acceptance Testing - PuppetConf 2014
Beaker: Automated, Cloud-Based Acceptance Testing - PuppetConf 2014
 
Django’s nasal passage
Django’s nasal passageDjango’s nasal passage
Django’s nasal passage
 
TDD super mondays-june-2014
TDD super mondays-june-2014TDD super mondays-june-2014
TDD super mondays-june-2014
 
Clearly, I Have Made Some Bad Decisions
Clearly, I Have Made Some Bad DecisionsClearly, I Have Made Some Bad Decisions
Clearly, I Have Made Some Bad Decisions
 
Who will test your tests?
Who will test your tests?Who will test your tests?
Who will test your tests?
 
Using the Power to Prove
Using the Power to ProveUsing the Power to Prove
Using the Power to Prove
 
DevSecCon Tel Aviv 2018 - Integrated Security Testing by Morgan Roman
DevSecCon Tel Aviv 2018 - Integrated Security Testing by Morgan RomanDevSecCon Tel Aviv 2018 - Integrated Security Testing by Morgan Roman
DevSecCon Tel Aviv 2018 - Integrated Security Testing by Morgan Roman
 
Puppet Camp Düsseldorf 2014: Continuously Deliver Your Puppet Code with Jenki...
Puppet Camp Düsseldorf 2014: Continuously Deliver Your Puppet Code with Jenki...Puppet Camp Düsseldorf 2014: Continuously Deliver Your Puppet Code with Jenki...
Puppet Camp Düsseldorf 2014: Continuously Deliver Your Puppet Code with Jenki...
 
Puppet Camp Duesseldorf 2014: Toni Schmidbauer - Continuously deliver your pu...
Puppet Camp Duesseldorf 2014: Toni Schmidbauer - Continuously deliver your pu...Puppet Camp Duesseldorf 2014: Toni Schmidbauer - Continuously deliver your pu...
Puppet Camp Duesseldorf 2014: Toni Schmidbauer - Continuously deliver your pu...
 
55 New Features in Java 7
55 New Features in Java 755 New Features in Java 7
55 New Features in Java 7
 
Unit Testing Lots of Perl
Unit Testing Lots of PerlUnit Testing Lots of Perl
Unit Testing Lots of Perl
 
owasp top 10
owasp top 10owasp top 10
owasp top 10
 
Continuous Integration Testing in Django
Continuous Integration Testing in DjangoContinuous Integration Testing in Django
Continuous Integration Testing in Django
 
Testing Salt States (part 1)
Testing Salt States (part 1)Testing Salt States (part 1)
Testing Salt States (part 1)
 
Rocket Fuelled Cucumbers
Rocket Fuelled CucumbersRocket Fuelled Cucumbers
Rocket Fuelled Cucumbers
 
Idiot proofing your code
Idiot proofing your codeIdiot proofing your code
Idiot proofing your code
 
PagerDuty | OSCON 2016 Failure Testing
PagerDuty | OSCON 2016 Failure TestingPagerDuty | OSCON 2016 Failure Testing
PagerDuty | OSCON 2016 Failure Testing
 
JUTE Workshop
JUTE WorkshopJUTE Workshop
JUTE Workshop
 

More from Kang-min Liu

Elasticsearch 實戰介紹
Elasticsearch 實戰介紹Elasticsearch 實戰介紹
Elasticsearch 實戰介紹
Kang-min Liu
 
Good Evils In Perl
Good Evils In PerlGood Evils In Perl
Good Evils In Perl
Kang-min Liu
 

More from Kang-min Liu (16)

o̍h Tai-gi
o̍h Tai-gio̍h Tai-gi
o̍h Tai-gi
 
The architecture of search engines in Booking.com
The architecture of search engines in Booking.comThe architecture of search engines in Booking.com
The architecture of search engines in Booking.com
 
Elasticsearch 實戰介紹
Elasticsearch 實戰介紹Elasticsearch 實戰介紹
Elasticsearch 實戰介紹
 
Perlbrew
PerlbrewPerlbrew
Perlbrew
 
Git
GitGit
Git
 
Learning From Ruby (Yapc Asia)
Learning From Ruby (Yapc Asia)Learning From Ruby (Yapc Asia)
Learning From Ruby (Yapc Asia)
 
YAPC::Tiny Introduction
YAPC::Tiny IntroductionYAPC::Tiny Introduction
YAPC::Tiny Introduction
 
Integration Test With Cucumber And Webrat
Integration Test With Cucumber And WebratIntegration Test With Cucumber And Webrat
Integration Test With Cucumber And Webrat
 
Good Evils In Perl
Good Evils In PerlGood Evils In Perl
Good Evils In Perl
 
Javascript Tutorial
Javascript TutorialJavascript Tutorial
Javascript Tutorial
 
Javascript Basic
Javascript BasicJavascript Basic
Javascript Basic
 
Handlino - RandomLife
Handlino - RandomLifeHandlino - RandomLife
Handlino - RandomLife
 
Jformino
JforminoJformino
Jformino
 
網頁程式還可以怎麼設計
網頁程式還可以怎麼設計網頁程式還可以怎麼設計
網頁程式還可以怎麼設計
 
OSDC.tw 2008 Lightening Talk
OSDC.tw 2008 Lightening TalkOSDC.tw 2008 Lightening Talk
OSDC.tw 2008 Lightening Talk
 
Happy Designer 20080329
Happy Designer 20080329Happy Designer 20080329
Happy Designer 20080329
 

Recently uploaded

Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
Joaquim Jorge
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
Enterprise Knowledge
 

Recently uploaded (20)

Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 

Test Continuous