diff options
| author | Misko Hevery | 2010-03-25 14:43:05 -0700 | 
|---|---|---|
| committer | Misko Hevery | 2010-03-25 14:43:05 -0700 | 
| commit | 4fa166866b97d4f4dbd21514dbd674347da0a109 (patch) | |
| tree | 6e6a79474f47481a596fc28cb61546f9506d6db0 /test/markupSpec.js | |
| parent | b814c79b58deeeeaa12b03261399ef80c0d6cc9f (diff) | |
| download | angular.js-4fa166866b97d4f4dbd21514dbd674347da0a109.tar.bz2 | |
input select-one now works
Diffstat (limited to 'test/markupSpec.js')
| -rw-r--r-- | test/markupSpec.js | 11 | 
1 files changed, 8 insertions, 3 deletions
| diff --git a/test/markupSpec.js b/test/markupSpec.js index 9e89af7b..8ea88f08 100644 --- a/test/markupSpec.js +++ b/test/markupSpec.js @@ -30,11 +30,11 @@ describe("markups", function(){    });    it('should translate {{}} in terminal nodes', function(){ -    compile('<select><option>Greet {{name}}!</option></select>'); -    expect(element.html()).toEqual('<option ng-bind-template="Greet {{name}}!"></option>'); +    compile('<select name="x"><option value="">Greet {{name}}!</option></select>'); +    expect(element.html()).toEqual('<option ng-bind-template="Greet {{name}}!" value=""></option>');      scope.set('name', 'Misko');      scope.updateView(); -    expect(element.html()).toEqual('<option ng-bind-template="Greet {{name}}!">Greet Misko!</option>'); +    expect(element.html()).toEqual('<option ng-bind-template="Greet {{name}}!" value="">Greet Misko!</option>');    });    it('should translate {{}} in attributes', function(){ @@ -46,4 +46,9 @@ describe("markups", function(){      expect(element.attr('src')).toEqual("http://server/a/b.png");    }); +  it('should populate value attribute on OPTION', function(){ +    compile('<select name="x"><option>A</option></select>'); +    expect(element.html()).toEqual('<option value="A">A</option>'); +  }); +  }); | 
