SlideShare una empresa de Scribd logo
1 de 25
Timmy Kokke
Silverlight / ASP.Net Developer
UNIT4 Internet Solutions
Expression Blend MVP
Basics of MVVM
Unit Testing
Silverlight Unit Testing framework
StatLight
Model
View
ViewModel
Model
View
ViewModel
Model
View
ViewModel
Model
View
ViewModel
Model
View
ViewModel
Databinding
Commands
Methods
Events
Unit tests are
consistent, isolated, fast and repeatable
Test only small units of work
TestName = Requirement
1 Assert per test
Self explanatory
Readability over Maintainability
Silverlight Toolkit
http://silverlight.codeplex.com
Runs in browser, no support for MsTest
[TestClass]
public class ExampleTests{
[TestMethod]
public class Adding_1_And_1_Should_Be_2(){
int result = 1 + 1;
Assert.AreEqual(2, result);
}
}
ServerSilverlightClient
GamesViewModel
GamesView
GamesDataService
WCF Ria Service
Database
UnitTest
ServerSilverlightClient
GamesViewModel
GamesView
GamesDataService
WCF Ria Service
Database
TestGamesDataService
IGamesDataService
GamesViewModelTests
[TestMethod]
[Tag("Rating")]
public void Setting_Ratings_Should_Set_AverageRating()
{
Rating rating = new Rating();
rating.GameplayRating = 4;
rating.GraphicsRating = 2;
Assert.AreEqual(3, rating.AverageRating);
}
[TestMethod]
[Description("Testing implementation of IDataErrorInfo."+
"Empty String Name should return Error.")]
public void Getting_ErrorInfo_For_Empty_Name_Should_Return_Error()
{
Rating errorInfo = new Rating {Name = string.Empty};
string result = errorInfo["Name"];
Assert.IsFalse(string.IsNullOrWhiteSpace(result));
}
[TestMethod]
[Asynchronous]
public void Executing_InitializeCommand_Should_Get_Publishers()
{
PublishersViewModel viewModel = new PublishersViewModel(
new TestPublishersDataService());
viewModel.PropertyChanged += (s, a) =>
{
Assert.IsTrue(viewModel.Publishers != null);
EnqueueTestComplete();
};
viewModel.InitializeCommand.Execute(null);
}
[TestMethod]
[Bug("Submitting is not implemented at this moment.")]
[WorkItem(1543)]
[Asynchronous]
public void Executing_SubmitCommand_Should_Navigate_To_GamesList()
{
DecoupledEventAggregator.GetInstance()
.GetEvent<NavigateToEvent>().Subscribe((a) =>
{
Assert.IsTrue(true);
EnqueueTestComplete();
});
RatingViewModel viewModel =
new RatingViewModel(new TestGamesDataService());
viewModel.SubmitCommand.Execute(null);
}
[TestMethod]
[Asynchronous]
[Timeout(250)]
public void Executing_GetMoreCommand_Should_Respond_In_250ms()
{
PublishersViewModel viewModel =
new PublishersViewModel(new TestPublishersDataService());
viewModel.PropertyChanged += (s, a) =>
{
Assert.IsTrue(true);
EnqueueTestComplete();
};
viewModel.GetMoreCommand.Execute(null);
}
[TestMethod]
[ExpectedException(typeof(ArgumentNullException))]
public void Executing_SubmitCommand_With_Null_Should_Throw_Exception()
{
RatingViewModel viewModel =
new RatingViewModel(new TestGamesDataService());
viewModel.SubmitCommand.Execute(null);
}
Command line tool
http://statlight.codeplex.com
Possible to integrate in TFS build
Continuous mode
http://silverlight.codeplex.com
http://statlight.codeplex.com
Timmy Kokke
info@timmykokke.com
http://twitter.com/sorskoot
http://www.timmykokke.com
Silverlight and Expression Usergroup
http://www.sixin.nl
9 November next meeting !

Más contenido relacionado

La actualidad más candente

SoftServe - "ASP.NET MVC як наступний крок у розвитку технології розробки Web...
SoftServe - "ASP.NET MVC як наступний крок у розвитку технології розробки Web...SoftServe - "ASP.NET MVC як наступний крок у розвитку технології розробки Web...
SoftServe - "ASP.NET MVC як наступний крок у розвитку технології розробки Web...SoftServe
 
Mocking with salesforce using Munit
Mocking with salesforce using MunitMocking with salesforce using Munit
Mocking with salesforce using MunitSon Nguyen
 
Invoke component demo in mule
Invoke component demo in muleInvoke component demo in mule
Invoke component demo in muleRamakrishna kapa
 
Head first asp.net mvc 2.0 rtt
Head first asp.net mvc 2.0 rttHead first asp.net mvc 2.0 rtt
Head first asp.net mvc 2.0 rttLanvige Jiang
 
Meetup - Getting Started with MVVM Light for WPF - 11 may 2019
Meetup  - Getting Started with MVVM Light for WPF - 11 may 2019Meetup  - Getting Started with MVVM Light for WPF - 11 may 2019
Meetup - Getting Started with MVVM Light for WPF - 11 may 2019iFour Technolab Pvt. Ltd.
 
Three Lessons about Gatling and Microservices
Three Lessons about Gatling and MicroservicesThree Lessons about Gatling and Microservices
Three Lessons about Gatling and MicroservicesDragos Manolescu
 
ASP .NET MVC Introduction & Guidelines
ASP .NET MVC Introduction & Guidelines  ASP .NET MVC Introduction & Guidelines
ASP .NET MVC Introduction & Guidelines Dev Raj Gautam
 
Model View Presenter presentation
Model View Presenter presentationModel View Presenter presentation
Model View Presenter presentationMichael Cameron
 
Test Driven Development using QUnit
Test Driven Development using QUnitTest Driven Development using QUnit
Test Driven Development using QUnitsatejsahu
 
Akka - Developing SEDA Based Applications
Akka - Developing SEDA Based ApplicationsAkka - Developing SEDA Based Applications
Akka - Developing SEDA Based ApplicationsBenjamin Darfler
 
Performance Test Automation With Gatling
Performance Test Automation  With GatlingPerformance Test Automation  With Gatling
Performance Test Automation With GatlingKnoldus Inc.
 
ASP.NET MVC.
ASP.NET MVC.ASP.NET MVC.
ASP.NET MVC.Ni
 
Getting started with MVC 5 and Visual Studio 2013
Getting started with MVC 5 and Visual Studio 2013Getting started with MVC 5 and Visual Studio 2013
Getting started with MVC 5 and Visual Studio 2013Thomas Robbins
 
Gatling overview
Gatling overviewGatling overview
Gatling overviewViral Jain
 
ASP.NET MVC Presentation
ASP.NET MVC PresentationASP.NET MVC Presentation
ASP.NET MVC PresentationVolkan Uzun
 

La actualidad más candente (20)

SoftServe - "ASP.NET MVC як наступний крок у розвитку технології розробки Web...
SoftServe - "ASP.NET MVC як наступний крок у розвитку технології розробки Web...SoftServe - "ASP.NET MVC як наступний крок у розвитку технології розробки Web...
SoftServe - "ASP.NET MVC як наступний крок у розвитку технології розробки Web...
 
Mocking with salesforce using Munit
Mocking with salesforce using MunitMocking with salesforce using Munit
Mocking with salesforce using Munit
 
What is MVC?
What is MVC?What is MVC?
What is MVC?
 
Asp.Net MVC Intro
Asp.Net MVC IntroAsp.Net MVC Intro
Asp.Net MVC Intro
 
ASP.NET MVC 3
ASP.NET MVC 3ASP.NET MVC 3
ASP.NET MVC 3
 
Invoke component demo in mule
Invoke component demo in muleInvoke component demo in mule
Invoke component demo in mule
 
Head first asp.net mvc 2.0 rtt
Head first asp.net mvc 2.0 rttHead first asp.net mvc 2.0 rtt
Head first asp.net mvc 2.0 rtt
 
Meetup - Getting Started with MVVM Light for WPF - 11 may 2019
Meetup  - Getting Started with MVVM Light for WPF - 11 may 2019Meetup  - Getting Started with MVVM Light for WPF - 11 may 2019
Meetup - Getting Started with MVVM Light for WPF - 11 may 2019
 
Three Lessons about Gatling and Microservices
Three Lessons about Gatling and MicroservicesThree Lessons about Gatling and Microservices
Three Lessons about Gatling and Microservices
 
ASP .NET MVC Introduction & Guidelines
ASP .NET MVC Introduction & Guidelines  ASP .NET MVC Introduction & Guidelines
ASP .NET MVC Introduction & Guidelines
 
Model View Controller (MVC)
Model View Controller (MVC)Model View Controller (MVC)
Model View Controller (MVC)
 
[TestWarez 2017] Behavior Driven Development in a complex environment - Consu...
[TestWarez 2017] Behavior Driven Development in a complex environment - Consu...[TestWarez 2017] Behavior Driven Development in a complex environment - Consu...
[TestWarez 2017] Behavior Driven Development in a complex environment - Consu...
 
Model View Presenter presentation
Model View Presenter presentationModel View Presenter presentation
Model View Presenter presentation
 
Test Driven Development using QUnit
Test Driven Development using QUnitTest Driven Development using QUnit
Test Driven Development using QUnit
 
Akka - Developing SEDA Based Applications
Akka - Developing SEDA Based ApplicationsAkka - Developing SEDA Based Applications
Akka - Developing SEDA Based Applications
 
Performance Test Automation With Gatling
Performance Test Automation  With GatlingPerformance Test Automation  With Gatling
Performance Test Automation With Gatling
 
ASP.NET MVC.
ASP.NET MVC.ASP.NET MVC.
ASP.NET MVC.
 
Getting started with MVC 5 and Visual Studio 2013
Getting started with MVC 5 and Visual Studio 2013Getting started with MVC 5 and Visual Studio 2013
Getting started with MVC 5 and Visual Studio 2013
 
Gatling overview
Gatling overviewGatling overview
Gatling overview
 
ASP.NET MVC Presentation
ASP.NET MVC PresentationASP.NET MVC Presentation
ASP.NET MVC Presentation
 

Similar a Unit Testing MVVM in Silverlight

Overview of Lab Management and TFS
Overview of Lab Management and TFSOverview of Lab Management and TFS
Overview of Lab Management and TFSChris Kadel, MBA
 
Turbocharge Your Automation Framework to Shorten Regression Execution Time
Turbocharge Your Automation Framework to Shorten Regression Execution TimeTurbocharge Your Automation Framework to Shorten Regression Execution Time
Turbocharge Your Automation Framework to Shorten Regression Execution TimeJosiah Renaudin
 
Silverlight2 Unit Testing Slides
Silverlight2 Unit Testing SlidesSilverlight2 Unit Testing Slides
Silverlight2 Unit Testing SlidesAndre John Cruz
 
An introduction to unit testing
An introduction to unit testingAn introduction to unit testing
An introduction to unit testingAdam Stephensen
 
Whats New In 2010 (Msdn & Visual Studio)
Whats New In 2010 (Msdn & Visual Studio)Whats New In 2010 (Msdn & Visual Studio)
Whats New In 2010 (Msdn & Visual Studio)Steve Lange
 
Automated Testing Of EPiServer CMS Sites
Automated Testing Of EPiServer CMS SitesAutomated Testing Of EPiServer CMS Sites
Automated Testing Of EPiServer CMS Sitesjoelabrahamsson
 
No More No Repro
No More No ReproNo More No Repro
No More No ReproAnna Russo
 
Evaluating Test Driven Development And Parameterized Unit Testing In Dot Net ...
Evaluating Test Driven Development And Parameterized Unit Testing In Dot Net ...Evaluating Test Driven Development And Parameterized Unit Testing In Dot Net ...
Evaluating Test Driven Development And Parameterized Unit Testing In Dot Net ...mdfachowdhury
 
Visual Studio 2010 Testing Overview
Visual Studio 2010 Testing OverviewVisual Studio 2010 Testing Overview
Visual Studio 2010 Testing OverviewSteve Lange
 
Test driven development in .Net - 2010 + Eclipse
Test driven development in .Net - 2010 + EclipseTest driven development in .Net - 2010 + Eclipse
Test driven development in .Net - 2010 + EclipseUTC Fire & Security
 
Test Automation Frameworks Using Selenium | Edureka
Test Automation Frameworks Using Selenium | EdurekaTest Automation Frameworks Using Selenium | Edureka
Test Automation Frameworks Using Selenium | EdurekaEdureka!
 
Full Testing Experience - Visual Studio and TFS 2010
 Full Testing Experience - Visual Studio and TFS 2010 Full Testing Experience - Visual Studio and TFS 2010
Full Testing Experience - Visual Studio and TFS 2010Ed Blankenship
 
Justmeans power point
Justmeans power pointJustmeans power point
Justmeans power pointjustmeanscsr
 
Modeling and Testing Dovetail in MagicDraw
Modeling and Testing Dovetail in MagicDrawModeling and Testing Dovetail in MagicDraw
Modeling and Testing Dovetail in MagicDrawGregory Solovey
 
Selenium Interview Questions and Answers | Selenium Tutorial | Selenium Train...
Selenium Interview Questions and Answers | Selenium Tutorial | Selenium Train...Selenium Interview Questions and Answers | Selenium Tutorial | Selenium Train...
Selenium Interview Questions and Answers | Selenium Tutorial | Selenium Train...Edureka!
 
Continuous performance testing
Continuous performance testingContinuous performance testing
Continuous performance testingSQALab
 

Similar a Unit Testing MVVM in Silverlight (20)

Overview of Lab Management and TFS
Overview of Lab Management and TFSOverview of Lab Management and TFS
Overview of Lab Management and TFS
 
Turbocharge Your Automation Framework to Shorten Regression Execution Time
Turbocharge Your Automation Framework to Shorten Regression Execution TimeTurbocharge Your Automation Framework to Shorten Regression Execution Time
Turbocharge Your Automation Framework to Shorten Regression Execution Time
 
Silverlight2 Unit Testing Slides
Silverlight2 Unit Testing SlidesSilverlight2 Unit Testing Slides
Silverlight2 Unit Testing Slides
 
An introduction to unit testing
An introduction to unit testingAn introduction to unit testing
An introduction to unit testing
 
Whats New In 2010 (Msdn & Visual Studio)
Whats New In 2010 (Msdn & Visual Studio)Whats New In 2010 (Msdn & Visual Studio)
Whats New In 2010 (Msdn & Visual Studio)
 
Automated Testing Of EPiServer CMS Sites
Automated Testing Of EPiServer CMS SitesAutomated Testing Of EPiServer CMS Sites
Automated Testing Of EPiServer CMS Sites
 
No More No Repro
No More No ReproNo More No Repro
No More No Repro
 
Evaluating Test Driven Development And Parameterized Unit Testing In Dot Net ...
Evaluating Test Driven Development And Parameterized Unit Testing In Dot Net ...Evaluating Test Driven Development And Parameterized Unit Testing In Dot Net ...
Evaluating Test Driven Development And Parameterized Unit Testing In Dot Net ...
 
Visual Studio 2010 Testing Overview
Visual Studio 2010 Testing OverviewVisual Studio 2010 Testing Overview
Visual Studio 2010 Testing Overview
 
Selenium
SeleniumSelenium
Selenium
 
Test driven development in .Net - 2010 + Eclipse
Test driven development in .Net - 2010 + EclipseTest driven development in .Net - 2010 + Eclipse
Test driven development in .Net - 2010 + Eclipse
 
Test Automation Frameworks Using Selenium | Edureka
Test Automation Frameworks Using Selenium | EdurekaTest Automation Frameworks Using Selenium | Edureka
Test Automation Frameworks Using Selenium | Edureka
 
Full Testing Experience - Visual Studio and TFS 2010
 Full Testing Experience - Visual Studio and TFS 2010 Full Testing Experience - Visual Studio and TFS 2010
Full Testing Experience - Visual Studio and TFS 2010
 
Kasi Resume
Kasi ResumeKasi Resume
Kasi Resume
 
Justmeans power point
Justmeans power pointJustmeans power point
Justmeans power point
 
Test automation within a scrum process
Test automation within a scrum processTest automation within a scrum process
Test automation within a scrum process
 
Modeling and Testing Dovetail in MagicDraw
Modeling and Testing Dovetail in MagicDrawModeling and Testing Dovetail in MagicDraw
Modeling and Testing Dovetail in MagicDraw
 
Selenium Interview Questions and Answers | Selenium Tutorial | Selenium Train...
Selenium Interview Questions and Answers | Selenium Tutorial | Selenium Train...Selenium Interview Questions and Answers | Selenium Tutorial | Selenium Train...
Selenium Interview Questions and Answers | Selenium Tutorial | Selenium Train...
 
Deep Dive Modern Apps Lifecycle with Visual Studio 2012: How to create cross ...
Deep Dive Modern Apps Lifecycle with Visual Studio 2012: How to create cross ...Deep Dive Modern Apps Lifecycle with Visual Studio 2012: How to create cross ...
Deep Dive Modern Apps Lifecycle with Visual Studio 2012: How to create cross ...
 
Continuous performance testing
Continuous performance testingContinuous performance testing
Continuous performance testing
 

Más de Timmy Kokke

Why front-end matters in 2019
Why front-end matters in 2019Why front-end matters in 2019
Why front-end matters in 2019Timmy Kokke
 
Centric - PWA WebCast
Centric - PWA WebCastCentric - PWA WebCast
Centric - PWA WebCastTimmy Kokke
 
Progressive Web Apps
Progressive Web AppsProgressive Web Apps
Progressive Web AppsTimmy Kokke
 
WebXR - Introduction and Workshop
WebXR - Introduction and WorkshopWebXR - Introduction and Workshop
WebXR - Introduction and WorkshopTimmy Kokke
 
Virtual Reality on the Web
Virtual Reality on the WebVirtual Reality on the Web
Virtual Reality on the WebTimmy Kokke
 
WebVR with Babylon.JS
WebVR with Babylon.JSWebVR with Babylon.JS
WebVR with Babylon.JSTimmy Kokke
 
Progressive Web Apps - Lightning Talk
Progressive Web Apps - Lightning TalkProgressive Web Apps - Lightning Talk
Progressive Web Apps - Lightning TalkTimmy Kokke
 
Progressive web apps
Progressive web appsProgressive web apps
Progressive web appsTimmy Kokke
 
JavaScript in Universal Windows Platform apps
JavaScript in Universal Windows Platform appsJavaScript in Universal Windows Platform apps
JavaScript in Universal Windows Platform appsTimmy Kokke
 
Store apps with AngularJS
Store apps with AngularJSStore apps with AngularJS
Store apps with AngularJSTimmy Kokke
 
Resharper - Next Steps
Resharper - Next StepsResharper - Next Steps
Resharper - Next StepsTimmy Kokke
 
TypeScript in Windows Store apps
TypeScript in Windows Store appsTypeScript in Windows Store apps
TypeScript in Windows Store appsTimmy Kokke
 
Reusing JavaScript knowledge in Windows Store apps
Reusing JavaScript knowledge in Windows Store appsReusing JavaScript knowledge in Windows Store apps
Reusing JavaScript knowledge in Windows Store appsTimmy Kokke
 
Beginning with blend
Beginning with blendBeginning with blend
Beginning with blendTimmy Kokke
 
What's Silverlight?
What's Silverlight?What's Silverlight?
What's Silverlight?Timmy Kokke
 
HTML5 - An Introduction
HTML5 - An IntroductionHTML5 - An Introduction
HTML5 - An IntroductionTimmy Kokke
 

Más de Timmy Kokke (19)

Back to Space
Back to SpaceBack to Space
Back to Space
 
Why front-end matters in 2019
Why front-end matters in 2019Why front-end matters in 2019
Why front-end matters in 2019
 
Centric - PWA WebCast
Centric - PWA WebCastCentric - PWA WebCast
Centric - PWA WebCast
 
Progressive Web Apps
Progressive Web AppsProgressive Web Apps
Progressive Web Apps
 
WebXR - Introduction and Workshop
WebXR - Introduction and WorkshopWebXR - Introduction and Workshop
WebXR - Introduction and Workshop
 
Virtual Reality on the Web
Virtual Reality on the WebVirtual Reality on the Web
Virtual Reality on the Web
 
WebVR with Babylon.JS
WebVR with Babylon.JSWebVR with Babylon.JS
WebVR with Babylon.JS
 
VR in a Box
VR in a BoxVR in a Box
VR in a Box
 
VR in a Box
VR in a BoxVR in a Box
VR in a Box
 
Progressive Web Apps - Lightning Talk
Progressive Web Apps - Lightning TalkProgressive Web Apps - Lightning Talk
Progressive Web Apps - Lightning Talk
 
Progressive web apps
Progressive web appsProgressive web apps
Progressive web apps
 
JavaScript in Universal Windows Platform apps
JavaScript in Universal Windows Platform appsJavaScript in Universal Windows Platform apps
JavaScript in Universal Windows Platform apps
 
Store apps with AngularJS
Store apps with AngularJSStore apps with AngularJS
Store apps with AngularJS
 
Resharper - Next Steps
Resharper - Next StepsResharper - Next Steps
Resharper - Next Steps
 
TypeScript in Windows Store apps
TypeScript in Windows Store appsTypeScript in Windows Store apps
TypeScript in Windows Store apps
 
Reusing JavaScript knowledge in Windows Store apps
Reusing JavaScript knowledge in Windows Store appsReusing JavaScript knowledge in Windows Store apps
Reusing JavaScript knowledge in Windows Store apps
 
Beginning with blend
Beginning with blendBeginning with blend
Beginning with blend
 
What's Silverlight?
What's Silverlight?What's Silverlight?
What's Silverlight?
 
HTML5 - An Introduction
HTML5 - An IntroductionHTML5 - An Introduction
HTML5 - An Introduction
 

Último

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 WorkerThousandEyes
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024The Digital Insurer
 
Exploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with MilvusExploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with MilvusZilliz
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWERMadyBayot
 
WSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering DevelopersWSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering DevelopersWSO2
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobeapidays
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProduct Anonymous
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...apidays
 
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...Angeliki Cooney
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherRemote DBA Services
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyKhushali Kathiriya
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businesspanagenda
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century educationjfdjdjcjdnsjd
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FMESafe Software
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FMESafe Software
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAndrey Devyatkin
 
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdfRising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdfOrbitshub
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native ApplicationsWSO2
 

Último (20)

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
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024
 
Exploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with MilvusExploring Multimodal Embeddings with Milvus
Exploring Multimodal Embeddings with Milvus
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
 
WSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering DevelopersWSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering Developers
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdfRising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
Understanding the FAA Part 107 License ..
Understanding the FAA Part 107 License ..Understanding the FAA Part 107 License ..
Understanding the FAA Part 107 License ..
 

Unit Testing MVVM in Silverlight

Notas del editor

  1. View => presentation of the data. Xaml
  2. ViewModel => the glue between View and Model.
  3. Model => domain object. the actual data/information. Example: contact (name, phone number, address)
  4. ViewModel -> Binding -> View -> Binding/Commands/Behaviors -> ViewModel ViewModel -> Method -> Model -> Events/Delegates -> ViewModel All client-server communication is async in Silverlight… makes testing a little more difficult. Testing mainly ViewModel… Sometimes a little View
  5. Let op met service calls of andere externe afhankelijkheden. Dit zijn Integration Tests.
  6. Test only small units of work TestName = Requirement 1 Assert per test Self explanatory Readability over Maintainability Naamgeving duidelijk -> underscores etc. Schrijf parameters als named parameters Vermijd dubbele code (DRY) -> gebruik functies als Make_GameViewModel
  7. Testframework is part of Silverlight toolkit Runs inside the browser, tools available to run from commandline (Statlight)… later more about this. Test classes can inherit from SilverlightTest -> Not supported in MSTest in visual studio (yet?) CodeCoverage is not available yet. Integratie in TFS build process wel mogelijk, via custom extension
  8. Start new Silverlight Project, add test project. Write some useless tests to demonstrate writing tests… Assert.AreEqual(1+1,3) Attributes: [TestClass] [TestMethod] 2e demo… Flow van attributes en test methoden… file importeren met example… breakpoints plaatsen [AssemblyInitialize] [AssemblyCleanup] -> 1x per assembly [ClassInitialize] [ClassCleanup] -> 1x per class [TestInitialize] [TestCleanup] -> 1x per test
  9. Client is equal for Publisher and Ratings.
  10. Show the demo project running for a sec
  11. Demo of the various attributes and different unit tests. [Tag] [Description] [Asynchronous] [Bug] [WorkItem] [TimeOut] [ExpectedException]
  12. Silverlight = asynchronous Many asynchronous tests Tests ends when EnqueueTestComplete is called
  13. To demonstrate -> uncomment // Thread.Sleep(TimeSpan.FromSeconds(5)); in TestPublishersDataService
  14. Demo of statlight Running commandline single and continuous
  15. Sixin Meeting (9 nov) about Designer-Developer lifecycle and userstories