SlideShare une entreprise Scribd logo
1  sur  13
TDD & UNIT TESTING RAIN Internal Training Presented by: Chase Brammer Training Date: 1/14/2009
RIA DEVELOPMENT CYCLE
PHASES OF TESTING Unit: Testing individual bits of ActionScript. Such as individual classes or methods. Integration: Testing how your app is actually wired together. Such as-- do the right events trigger the right commands? Acceptance: Testing the whole app. Including how it behaves in a realistic deployment environment. Usability: Testing the flow of human interactions with the application.
[object Object],[object Object],[object Object],[object Object],[object Object],"It's about figuring out what you are trying to do before you run off to try to do it. You write a specification that nails down a small aspect of behavior in a concise, unambiguous, and executable form. It's that simple. Does that mean you write tests? No. It means you write  specifications  of what your code will have to do. It means you specify the behavior of your code ahead of time. But not far ahead of time. In fact, just before you write the code is best because that's when you have as much information at hand as you will up to that point."  WHO, WHAT AND WHY
Testing is like source control.  You don't know how much you need until you start using it. WHO, WHAT AND WHY
HOW IT CAN HELP US (because we are way better than 2advanced) Faster overall development Less expensive (development and maintenance cycles) Less complicated code bases More independent and reusable code Less time and problems with regression testing Break new ground 1  | 2  | 3  | 4  | 5  | 6  | HOW WILL HURT US/PROBLEMS Developer learning curve Slower initial development speed Problems with a MVC type framework (Nimbus, Cairngorm, PureMVC) Poor Documentation 1  | 2  | 3  | 4  |
Yes I and many others within AC use TDD. I understand your frustration with the lack of information out there. I've talked at the last MAX conference about it and AFAIK this will be on Adobe TV soon. I'll ask when exactly. Also, I plan on publishing a lot more around this area.     Best, Alex   Alex Uhlmann  Senior Consultant (Rich Internet Applications) Adobe Consulting POOR DOCUMENTATION
TEST DRIVEN DEVELOPMENT (TDD) Add a test Run tests, see if new one fails Write some code Run tests, watch them succeed Re-factor Repeat 1  | 2  | 3  | 4  | 5  | 6  | TDD Cycle Test-driven development  (TDD), a concept of Extreme Programming, is a technique that uses short development iterations based on pre-written test cases that define desired improvements or new functions. We all sit down and write a piece of code in context, and even if we can sit down and fix that code, it is very difficult to see the relations of that piece of code with the rest of the application.  Especially when working with large teams and projects.
KEY CONCEPTS Write tests firsts to develop expectations A good unit test exercises a single method Decoupled code Program to interfaces Every bug should have a unit test that exercises it before fixing it. | | | | |
TERMS Assertion: An assertion is a statement of expected outcome. In other words, it is the expected result of your test. Test Fixture: Things that are constant across all of your tests.  setUp() and tearDown() functions. Test Case: A test case is the smallest unit of testing. It checks for a specific response to a particular set of inputs. Extends TestCase. Test Suite: A grouping of test cases.  May contain test cases and other test suites. Test Runner: A test runner is a component that often has a graphical interface and displays the outcome of our tests.
KEY CONCEPTS Lets get into the code!
USEFUL LINKS Unit Testing with FlexUnit - InsideRIA   Adobe - Developer Center : Unit testing and Test Driven Development (TDD) for Flex and ActionScript 3.0   Steven Webster: Unit Testing and Test Coverage with Flex   Flex unit testing and continuous integration: Part 1 of 2   The Flex Show: Flex Show Episode 64: Interview with Michael labriola about Fluint Unit Testing Commands - Part 2 - Mocking Command Dependencies | Allen Manning SettingExpectations - mock-as3 - Google Code - Demonstrates the various expectations that can be set.   Continuous integration - Wikipedia, the free encyclopedia   Leif Wells: RIA Evangelist: 10 Questions About FlexUnit and Cairngorm   Flex cookbook beta - Automated TestSuite Generation Flex cookbook beta - Testing Visual Components with FlexUnit Unit testing - Wikipedia, the free encyclopedia   Google Testing Blog: TotT: Use EasyMock   Daniel R.: Asynchronous Testing with FlexUnit   Cairngorm | Allen Manning   Tom Sugden: EventfulTestCase: a FlexUnit extension for testing event dispatching   Using mock objects for complex unit tests   joeberkovitz.com » Moment of Weakness: Weak Event Listeners Can Be Dangerous
Thank You

Contenu connexe

Dernier

Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupFlorian Wilhelm
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsRizwan Syed
 
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage CostLeverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage CostZilliz
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsSergiu Bodiu
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek SchlawackFwdays
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piececharlottematthew16
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfAlex Barbosa Coqueiro
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 
From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .Alan Dix
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii SoldatenkoFwdays
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024Lorenzo Miniero
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLScyllaDB
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Enterprise Knowledge
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 3652toLead Limited
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationSlibray Presentation
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubKalema Edgar
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenHervé Boutemy
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionDilum Bandara
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 

Dernier (20)

Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project Setup
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL Certs
 
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage CostLeverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platforms
 
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptxE-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piece
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdf
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 
From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQL
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck Presentation
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding Club
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache Maven
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An Introduction
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 

En vedette

Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsPixeldarts
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthThinkNow
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfmarketingartwork
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024Neil Kimberley
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)contently
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024Albert Qian
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsKurio // The Social Media Age(ncy)
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Search Engine Journal
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summarySpeakerHub
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next Tessa Mero
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentLily Ray
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best PracticesVit Horky
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project managementMindGenius
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...RachelPearson36
 
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Applitools
 
12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at WorkGetSmarter
 

En vedette (20)

Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
 
Skeleton Culture Code
Skeleton Culture CodeSkeleton Culture Code
Skeleton Culture Code
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
 
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
 
12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work
 

TDD and Unit Testing

  • 1. TDD & UNIT TESTING RAIN Internal Training Presented by: Chase Brammer Training Date: 1/14/2009
  • 3. PHASES OF TESTING Unit: Testing individual bits of ActionScript. Such as individual classes or methods. Integration: Testing how your app is actually wired together. Such as-- do the right events trigger the right commands? Acceptance: Testing the whole app. Including how it behaves in a realistic deployment environment. Usability: Testing the flow of human interactions with the application.
  • 4.
  • 5. Testing is like source control. You don't know how much you need until you start using it. WHO, WHAT AND WHY
  • 6. HOW IT CAN HELP US (because we are way better than 2advanced) Faster overall development Less expensive (development and maintenance cycles) Less complicated code bases More independent and reusable code Less time and problems with regression testing Break new ground 1 | 2 | 3 | 4 | 5 | 6 | HOW WILL HURT US/PROBLEMS Developer learning curve Slower initial development speed Problems with a MVC type framework (Nimbus, Cairngorm, PureMVC) Poor Documentation 1 | 2 | 3 | 4 |
  • 7. Yes I and many others within AC use TDD. I understand your frustration with the lack of information out there. I've talked at the last MAX conference about it and AFAIK this will be on Adobe TV soon. I'll ask when exactly. Also, I plan on publishing a lot more around this area.    Best, Alex   Alex Uhlmann Senior Consultant (Rich Internet Applications) Adobe Consulting POOR DOCUMENTATION
  • 8. TEST DRIVEN DEVELOPMENT (TDD) Add a test Run tests, see if new one fails Write some code Run tests, watch them succeed Re-factor Repeat 1 | 2 | 3 | 4 | 5 | 6 | TDD Cycle Test-driven development (TDD), a concept of Extreme Programming, is a technique that uses short development iterations based on pre-written test cases that define desired improvements or new functions. We all sit down and write a piece of code in context, and even if we can sit down and fix that code, it is very difficult to see the relations of that piece of code with the rest of the application. Especially when working with large teams and projects.
  • 9. KEY CONCEPTS Write tests firsts to develop expectations A good unit test exercises a single method Decoupled code Program to interfaces Every bug should have a unit test that exercises it before fixing it. | | | | |
  • 10. TERMS Assertion: An assertion is a statement of expected outcome. In other words, it is the expected result of your test. Test Fixture: Things that are constant across all of your tests. setUp() and tearDown() functions. Test Case: A test case is the smallest unit of testing. It checks for a specific response to a particular set of inputs. Extends TestCase. Test Suite: A grouping of test cases. May contain test cases and other test suites. Test Runner: A test runner is a component that often has a graphical interface and displays the outcome of our tests.
  • 11. KEY CONCEPTS Lets get into the code!
  • 12. USEFUL LINKS Unit Testing with FlexUnit - InsideRIA Adobe - Developer Center : Unit testing and Test Driven Development (TDD) for Flex and ActionScript 3.0 Steven Webster: Unit Testing and Test Coverage with Flex Flex unit testing and continuous integration: Part 1 of 2 The Flex Show: Flex Show Episode 64: Interview with Michael labriola about Fluint Unit Testing Commands - Part 2 - Mocking Command Dependencies | Allen Manning SettingExpectations - mock-as3 - Google Code - Demonstrates the various expectations that can be set. Continuous integration - Wikipedia, the free encyclopedia Leif Wells: RIA Evangelist: 10 Questions About FlexUnit and Cairngorm Flex cookbook beta - Automated TestSuite Generation Flex cookbook beta - Testing Visual Components with FlexUnit Unit testing - Wikipedia, the free encyclopedia Google Testing Blog: TotT: Use EasyMock Daniel R.: Asynchronous Testing with FlexUnit Cairngorm | Allen Manning Tom Sugden: EventfulTestCase: a FlexUnit extension for testing event dispatching Using mock objects for complex unit tests joeberkovitz.com » Moment of Weakness: Weak Event Listeners Can Be Dangerous