Last active
December 13, 2015 17:39
-
-
Save sourishkrout/4949756 to your computer and use it in GitHub Desktop.
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
/*global it:true */ | |
"use strict"; | |
var describeWd = require("./helpers/driverblock.js").describeForApp('TestApp') | |
, should = require('should'); | |
describeWd('elementByTagName', function(h) { | |
it('should return element using the web driver api', function(done) { | |
h.driver.elementByTagName('button', function(err, element) { | |
should.exist(element.value); | |
done(); | |
}); | |
}); | |
it('should return element but also leak uiautomation js all over the place', function(done) { | |
var mainWindow = 'UIATarget.localTarget().frontMostApp().mainWindow()'; | |
h.driver.execute(mainWindow + '.buttons()[0].name();', [], function(err, result) { | |
result.should.equal('ComputeSumButton'); | |
done(); | |
}); | |
}); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment