aboutsummaryrefslogtreecommitdiffstats
path: root/src/ng/directive/select.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/ng/directive/select.js')
-rw-r--r--src/ng/directive/select.js16
1 files changed, 9 insertions, 7 deletions
diff --git a/src/ng/directive/select.js b/src/ng/directive/select.js
index 0e64cc43..c4498f81 100644
--- a/src/ng/directive/select.js
+++ b/src/ng/directive/select.js
@@ -120,15 +120,17 @@ var ngOptionsMinErr = minErr('ngOptions');
</div>
</div>
</doc:source>
- <doc:scenario>
+ <doc:protractor>
it('should check ng-options', function() {
- expect(binding('{selected_color:color}')).toMatch('red');
- select('color').option('0');
- expect(binding('{selected_color:color}')).toMatch('black');
- using('.nullable').select('color').option('');
- expect(binding('{selected_color:color}')).toMatch('null');
+ expect(element(by.binding('{selected_color:color}')).getText()).toMatch('red');
+ element.all(by.select('color')).first().click();
+ element.all(by.css('select[ng-model="color"] option')).first().click();
+ expect(element(by.binding('{selected_color:color}')).getText()).toMatch('black');
+ element(by.css('.nullable select[ng-model="color"]')).click();
+ element.all(by.css('.nullable select[ng-model="color"] option')).first().click();
+ expect(element(by.binding('{selected_color:color}')).getText()).toMatch('null');
});
- </doc:scenario>
+ </doc:protractor>
</doc:example>
*/