A software adventure
https://www.flickr.com/photos/nancyvioletavelez/
Infinite possibility.
https://www.flickr.com/photos/aigle_dore/
https://www.flickr.com/photos/patt-ach/
JavaScript
Selenium
Sauce Labs
Python
Jasmine
PhantomJS
Expensive to write.
--------------
--------------
Cheap to write
run
maintain
get results
maintain
run
get results
https://www.flickr.com/photos/calsidyrose/
it("should detect an empty object", function(){
expect(Util.isEmptyObject({})).toEqual(true);
expect(Util.isEmptyObject({name:"ricky"})).toEqual(false);
});
@Test
public void noApiKey() {
final String actualResponse = getResponse(RULE, "/nitro", String.class);
String expected = "{\"status\":\"error\",\"message\":\"apiKey parameter is required\"}";
assertThat("The /nitro should complain about apiKey", actualResponse,
is(equalTo(expected)));
}
Leverage unit test for 90% of your test coverage
Leverage integration tests for 10% of your test coverage (SMOKE TEST)
https://www.flickr.com/photos/vonlind/
Existing Monolithic Application
No Documentation
https://www.flickr.com/photos/calsidyrose/
1. Document functionality
2. Agree to functionality across teams
3. Write Manual Tests
4. Evaluate to see if we can automate it
Don't do it all at once. Iterate on it. We created a ticket for each page. We pull a few in each iteration. This way we are not completely blocking our product to market pipeline.
https://www.flickr.com/photos/texturetime/
https://www.flickr.com/photos/30127497@N04/
https://www.flickr.com/photos/30127497@N04/
define([
'jquery'
], function($) {
describe("Namespacing", function(){
it("window.$ should not be defined", function(){
expect(window.$).toEqual(null);
});
it("window.jQuery should not be defined", function(){
expect(window.jQuery).toEqual(null);
})
});
});
it("should detect email address", function() {
expect(Util.isEmail("ricky@ricardo.com")).toEqual(true);
expect(Util.isEmail("234")).toEqual(false);
expect(Util.isEmail("1@1.1")).toEqual(false);
expect(Util.isEmail("ricky.guy@ricardo.com")).toEqual(true);
});
it("should detect an empty object", function(){
expect(Util.isEmptyObject({})).toEqual(true);
expect(Util.isEmptyObject({name:"ricky"})).toEqual(false);
});
// Ought to be named stripAngleBrackets
it("should strip angle brackets", function(){
expect(Util.stripHTML("<h1>")).toEqual('h1');
});
it("should escape HTML", function(){
expect(Util.escapeHTML("<h1>Page Title</h1>")).toEqual('<h1>Page Title</h1>');
});
it("should escape double qoutes", function() {
expect(Util.escapeDoubleQuotes("So I says to him, \" Walt! \""))
.toEqual('So I says to him, " Walt! "');
});
<target name="runJasmineTests">
<property name="specrunner.dir" location="./${test.dir}"/>
<exec executable="phantomjs" newenvironment="false"
dir="./${test.dir}" failonerror="true" osfamily="unix">
<arg value="run-jasmine.js"/>
<arg line="${specrunner.dir}/SpecRunner.html" />
</exec>
</target>
"Speed is the new currency of development"
Dreamforce
photo by Sean Turbidy
Releasing often while maintaining quality
https://www.flickr.com/photos/skipmoore/
https://www.flickr.com/photos/ifindkarma/