Sunday, November 2, 2014

Canoo WebTest test scenario is in fact

Canoo WebTest test scenario is in fact "only" a set of Ant-task and therefore we have probably not surprising that the records Canoo WebTest test scenarios are traditional XML records. If you do not want to write test cases in XML format, there is another alternative. Groovy and Maven. And directly in Eclipse.
We start by downloading the version Maven [http://maven.apache.org/download.html]. At the time of this writing the current "apache-maven-3.1.0". After setting up the system "path" to "X: \ apache-maven-3.1.0 \ bin \" will begin with a Maven project.
Zeditujeme pom.xml generated in three steps. Add WebTest as 'dependency' <dependency> <groupId> com.canoo.webtest </ groupId> benchmark <artifactId> webtest </ artifactId> <version> 3.1-SNAPSHOT </ version> </ dependency> add reference to Maven-WebTest repository: <repositories> <repository> benchmark <id> webtest_dependencies_snapshot </ id> <name> WebTest dependencies </ name> benchmark <url> http://webtest.canoo.com/webtest/m2-repo-snapshots </ url> < / repository> benchmark </ repositories> GMaven configure the plugin: <build> <plugins> <plugin> <groupId> org.codehaus.groovy.maven </ groupId> <artifactId> gmaven-plugin </ artifactId> <version> 1.0-rc -5 </ version> <executions> <execution> <goals> <goal> compile </ goal> <goal> testCompile </ goal> </ goals> </ execution> </ executions> </ plugin> <plugin> <groupId> org.codehaus.mojo </ groupId> <artifactId> build-helper-maven-plugin </ artifactId> <executions> <execution> <id> add-test-source </ id> <phase> generate-sources </ phase> <goals> <goal> add-test-source </ goal> </ goals> <configuration> <sources> <source> src / test / groovy </ source> </ sources> </ configuration> < / execution> </ executions> </ plugin> </ plugins> </ build>
While creating eclipse project from between the Internet Download current JAR files that can be found in the ".M2", benchmark see the example in "c: \ Documents and Settings \ hesteric \ .M2". I moved to the directory .M2 installation directory for the Maven-disk F: \.
Our first groovy test, which will test sme.sk might look like this: package my.domain import com.canoo.webtest.WebtestCase / ** *author hesteric * * / class MyFirstWebTest extends WebtestCase testSme {void () {webtest ( "We test sme.sk") {invoke url: "http://www.sme.sk", description: "Go to Sme.sk" verifyTitle "SME.sk" // Fail test here ...}}}
Wrong document benchmark title found !. Expected value "SME.sk" but got "SME.sk | SME daily - Most popular news in Slovakia" Step: VerifyTitle at: with (TaskName = "verifyTitle") at com.canoo.webtest.steps.verify.VerifyTitle.doExecute (VerifyTitle.java:26)
CTO for Java and .Net applications. Authorized collaborator on the project Canoo Webtest. The holder of the certificate MCTS and MCPD for SharePoint server. The IT works 20 years, the good old Turbo Pascal from Borland, via Java in Eclipse to C # in Visual Studio. The administrator mathematical portal www.priklady.eu
Improve usability of your site and earn more SSL - another serious error Startupy a one-euro eseročky: perhaps it is better to set up a standard company BarCamp is again in Bratislava there and I will not miss Startup Weekend 2014 Žilina How to save money and time in recruitment Azure : Android - modification of an existing application in order to use the mobile service Slovak benchmark StartUp embarks on unpaid invoices fight not only in Slovakia Azure: Windows 8.1 - create Android applications that use mobile service Why you should not miss out on OpenSlave 2014? Rise & Shine, for the second time coming to Prague. Become part of the largest events linking young and enterprising benchmark people. benchmark Live: Granting Slovak Computer "Oscar" Live 2014: IT Conference SUMMIT 2014 A brief introduction to a new programming language Swift JBehave: Behavior-Driven Testing Blog Categories
Blog (323) poznáme.it (197) Content Management (2) Infrastructure (9) Service Management (2) Knowledge Management (2) Open Source (4) Social Networking (5) Games (2) website optimization (2) web development (10) Marketing (6) Enterprise Architecture (8) Application Architecture (9) IT Architecture (11) CRM (2) DWH / BI (13) Big Data (2) BPM (5) UX Design (6) Web Design (17) Agile (16) Project Management (17) Programming (52) Testing (29) Technology (34) Mobile Technology (14) Cloud (5) Security (14) Outsourcing (3) Consulting (10) IT vs. other (5) ja.som.it (39) Startup (8) Leader (1) Freedom at work (4) soil

No comments:

Post a Comment