Created
August 26, 2015 21:02
-
-
Save toranb/8c31665ba0222703b203 to your computer and use it in GitHub Desktop.
a simple ember example showing how to select multiple items in a "multi select" (integration testing)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
test('multi select in a ember integration test', function(assert) { | |
//setup your model and other component state ... | |
this.render(hbs`{{my-multi-select model=model options=options}}`); | |
this.$('.some-multi-select > option[value="' + MY_NEW_ID + '"]').prop('selected',true).trigger('change'); | |
assert.equal(model.get('related_things').get('length'), new_count_with_added_item); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment