aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--test/scenario/DSLSpec.js5
1 files changed, 4 insertions, 1 deletions
diff --git a/test/scenario/DSLSpec.js b/test/scenario/DSLSpec.js
index 3c16876d..bed1f008 100644
--- a/test/scenario/DSLSpec.js
+++ b/test/scenario/DSLSpec.js
@@ -11,6 +11,7 @@ describe("DSL", function() {
};
executeStep = function(step, html, callback) {
lastDocument =_jQuery('<div>' + html + '</div>');
+ _jQuery(document.body).append(lastDocument);
var specThis = {
testWindow: window,
testDocument: lastDocument
@@ -32,8 +33,10 @@ describe("DSL", function() {
it('should select', function() {
input('gender').select('female');
expect(lastStep.name).toEqual("Select radio 'gender' to 'female'");
- executeStep(lastStep, '<input type="radio" name="0@gender" value="male"/>' +
+ executeStep(lastStep,
+ '<input type="radio" name="0@gender" value="male" checked/>' +
'<input type="radio" name="0@gender" value="female"/>');
+ expect(lastDocument.find(':radio:checked').length).toEqual(1);
expect(lastDocument.find(':radio:checked').val()).toEqual('female');
});
});