2016-07-26 01:42:39 +02:00
|
|
|
QUnit.test('agree to terms', function (assert) {
|
|
|
|
var done = assert.async()
|
|
|
|
|
|
|
|
// Select the mock app root
|
|
|
|
var app = $('iframe').contents().find('#app-content .mock-app-root')
|
|
|
|
|
2016-10-06 04:49:53 +02:00
|
|
|
app.find('.markdown').prop('scrollTop', 100000000)
|
2016-07-26 01:42:39 +02:00
|
|
|
|
|
|
|
wait().then(function() {
|
2016-10-06 04:49:53 +02:00
|
|
|
app.find('button').click()
|
2016-10-12 00:50:02 +02:00
|
|
|
}).then(function() {
|
|
|
|
return wait()
|
|
|
|
}).then(function() {
|
|
|
|
var title = app.find('h1').text()
|
|
|
|
assert.equal(title, 'MetaMask', 'title screen')
|
2016-07-26 01:42:39 +02:00
|
|
|
|
2016-10-12 00:50:02 +02:00
|
|
|
var buttons = app.find('button')
|
|
|
|
assert.equal(buttons.length, 2, 'two buttons: create and restore')
|
2016-07-26 01:42:39 +02:00
|
|
|
|
2016-10-12 00:50:02 +02:00
|
|
|
done()
|
2016-07-26 01:42:39 +02:00
|
|
|
})
|
2016-10-06 04:49:53 +02:00
|
|
|
|
|
|
|
// Wait for view to transition:
|
2016-07-26 01:42:39 +02:00
|
|
|
})
|