docs(guide/module): add protractor tests

This commit is contained in:
Peter Bacon Darwin
2014-07-18 11:05:39 +01:00
parent cc8eb91665
commit 243d9ac72c

View File

@@ -45,6 +45,12 @@ I'm in a hurry. How do I get a Hello World module working?
};
});
</file>
<file name="protractor.js" type="protractor">
it('should add Hello to the name', function() {
expect(element(by.binding("{{ 'World' | greet }}")).getText()).toEqual('Hello, World!');
});
</file>
</example>
Important things to notice:
@@ -75,7 +81,7 @@ The above is a suggestion. Tailor it to your needs.
<example module='xmpl'>
<file name="index.html">
<div ng-controller="XmplController">
{{ greeting }}!
{{ greeting }}
</div>
</file>
@@ -117,6 +123,13 @@ The above is a suggestion. Tailor it to your needs.
});
</file>
<file name="protractor.js" type="protractor">
it('should add Hello to the name', function() {
expect(element(by.binding("{{ greeting }}")).getText()).toEqual('Bonjour World!');
});
</file>
</example>