Date post: | 07-May-2015 |
Category: |
Documents |
Upload: | sampetruda |
View: | 660 times |
Download: | 4 times |
Welcome!Welcome!
Chicago Ajax DevelopersChicago Ajax Developers
Friday, June 12 2009Friday, June 12 2009
Who Am I?Who Am I?
Arthur KayArthur Kay Web Developer at GFX InternationalWeb Developer at GFX International
ASP.NET and AJAXASP.NET and AJAX
Who Am I?Who Am I?
10+ years of Web Development10+ years of Web Development .NET, Classic ASP, PHP, Python, .NET, Classic ASP, PHP, Python,
JavaScript, CSSJavaScript, CSS Analytics, SEO, Email MarketingAnalytics, SEO, Email Marketing
www.akawebdesign.comwww.akawebdesign.com blog.akawebdesign.comblog.akawebdesign.com
Chicago Ajax DevelopersChicago Ajax Developers
Monthly JavaScript MeetupMonthly JavaScript Meetup
www.ChicagoAjaxDevelopers.comwww.ChicagoAjaxDevelopers.com
Our First Meeting!Our First Meeting!
AgendaAgenda
An Introduction to ExtJSAn Introduction to ExtJS Unit Testing in ExtJSUnit Testing in ExtJS
ExtJSExtJS
Open Source JavaScript library for Open Source JavaScript library for building rich internet applications.building rich internet applications.
Object-oriented, customizable widgetsObject-oriented, customizable widgets www.extjs.comwww.extjs.com Huge community of developers, forumsHuge community of developers, forums Ext Conference 2009Ext Conference 2009 Lightweight Ext CoreLightweight Ext Core Ext GWT (Java)Ext GWT (Java)
ExtJS ExampleExtJS Example
Viewport and GridViewport and Grid UI for my Unit Testing exampleUI for my Unit Testing example
About Unit TestingAbout Unit Testing
Confidence that your application works Confidence that your application works when future changes are made.when future changes are made.
““Unit” – the smallest testable part of an Unit” – the smallest testable part of an application:application: FunctionFunction ClassClass
Commonly done in C#, Java and similar Commonly done in C#, Java and similar languages.languages.
Unit Testing in JavaScriptUnit Testing in JavaScript
It sucks. It sucks. Common problems:Common problems:
Limited to browserLimited to browser Global namespaceGlobal namespace Latency between client/serverLatency between client/server
If JS developers can accept these If JS developers can accept these limitations, Unit Testing is great!limitations, Unit Testing is great!
Unit Testing in JavaScriptUnit Testing in JavaScript
Other JS Libraries have Unit Test classesOther JS Libraries have Unit Test classes YUI > YUI TestYUI > YUI Test jQuery > QUnitjQuery > QUnit Prototype > TestCasePrototype > TestCase Script.aculo.us > UnitTestScript.aculo.us > UnitTest
ExtJS has nothing.ExtJS has nothing.
Unit Testing in ExtJSUnit Testing in ExtJS
Ext.ux.UnitTestExt.ux.UnitTest()() TestArray[] - arrayTestArray[] - array Store() - objectStore() - object Test() - objectTest() - object NewUnitTest() - functionNewUnitTest() - function
Ext.ux.UnitTest.Test()Ext.ux.UnitTest.Test()
generateGuid()generateGuid() wait()wait() assertEquals()assertEquals() assertNotEquals()assertNotEquals() assertUndefinedOrNullassertUndefinedOrNull()() assertNotUndefinedOrNullassertNotUndefinedOrNull()() assertContainsassertContains()() assertNotContainsassertNotContains()()
Let’s Build Some Tests!Let’s Build Some Tests!
ResourcesResources
aKaaKa Web Design – Web Design – ExtJSExtJS Unit Testing Unit Testing ExtJSExtJS - Unit Testing Thread - Unit Testing Thread