pull/3094/head
yann300 7 years ago
parent cc2de917fd
commit 77ca891fd9
  1. 6
      test-browser/tests/ballot.js
  2. 6
      test-browser/tests/compiling.js
  3. 1
      test-browser/tests/units/testRecorder.js

@ -36,7 +36,7 @@ function runTests (browser, testData) {
}).click('.runView') }).click('.runView')
.setValue('input[placeholder="uint8 _numProposals"]', '1') .setValue('input[placeholder="uint8 _numProposals"]', '1')
.click('#runTabView button[class^="instanceButton"]') .click('#runTabView button[class^="instanceButton"]')
.pause(500) .waitForElementPresent('.instance:nth-of-type(2)')
.click('.instance:nth-of-type(2)') .click('.instance:nth-of-type(2)')
.testFunction('delegate - transact (not payable)', '0x0571a2439ea58bd349dd130afb8aff62a33af14c06de0dbc3928519bdf13ce2e', .testFunction('delegate - transact (not payable)', '0x0571a2439ea58bd349dd130afb8aff62a33af14c06de0dbc3928519bdf13ce2e',
`[vm]\nfrom:0xca3...a733c\nto:Ballot.delegate(address) 0x692...77b3a\nvalue:0 wei\ndata:0x5c1...4d2db\nlogs:0\nhash:0x057...3ce2e`, `[vm]\nfrom:0xca3...a733c\nto:Ballot.delegate(address) 0x692...77b3a\nvalue:0 wei\ndata:0x5c1...4d2db\nlogs:0\nhash:0x057...3ce2e`,
@ -85,10 +85,10 @@ function runTests (browser, testData) {
done() done()
}) })
}) })
.click('.instance:nth-of-type(2)') .pause(500)
.perform((client, done) => { .perform((client, done) => {
console.log('delegate - transact (not payable)') console.log('delegate - transact (not payable)')
browser.testFunction('delegate - transact (not payable)', '0xd3cd54e2f76f3993078ecf9e1b54a148def4520afc141a182293b3610bddf10f', browser.waitForElementPresent('.instance:nth-of-type(2)').click('.instance:nth-of-type(2)').testFunction('delegate - transact (not payable)', '0xd3cd54e2f76f3993078ecf9e1b54a148def4520afc141a182293b3610bddf10f',
`[vm]\nfrom:0xca3...a733c\nto:Ballot.delegate(address) 0x692...77b3a\nvalue:0 wei\ndata:0x5c1...4d2db\nlogs:0\nhash:0xd3c...df10f`, `[vm]\nfrom:0xca3...a733c\nto:Ballot.delegate(address) 0x692...77b3a\nvalue:0 wei\ndata:0x5c1...4d2db\nlogs:0\nhash:0xd3c...df10f`,
{types: 'address to', values: '"0x4b0897b0513fdc7c541b6d9d7e929c4e5364d2db"'}, null, null, () => { done() }) {types: 'address to', values: '"0x4b0897b0513fdc7c541b6d9d7e929c4e5364d2db"'}, null, null, () => { done() })
}).end() }).end()

@ -39,7 +39,7 @@ function testSimpleContract (browser, callback) {
contractHelper.testContracts(browser, 'Untitled.sol', sources[0]['browser/Untitled.sol'], ['TestContract'], function () { contractHelper.testContracts(browser, 'Untitled.sol', sources[0]['browser/Untitled.sol'], ['TestContract'], function () {
browser.click('.runView') browser.click('.runView')
.click('#runTabView button[class^="instanceButton"]') .click('#runTabView button[class^="instanceButton"]')
.pause(500) .waitForElementPresent('.instance:nth-of-type(2)')
.click('.instance:nth-of-type(2)') .click('.instance:nth-of-type(2)')
.click('#runTabView .instance div[class^="title"]') .click('#runTabView .instance div[class^="title"]')
.click('#runTabView .instance div[class^="title"]') .click('#runTabView .instance div[class^="title"]')
@ -70,7 +70,7 @@ function testReturnValues (browser, callback) {
contractHelper.testContracts(browser, 'returnValues.sol', sources[1]['browser/returnValues.sol'], ['testReturnValues'], function () { contractHelper.testContracts(browser, 'returnValues.sol', sources[1]['browser/returnValues.sol'], ['testReturnValues'], function () {
browser.click('.runView') browser.click('.runView')
.click('#runTabView button[class^="instanceButton"]') .click('#runTabView button[class^="instanceButton"]')
.pause(500) .waitForElementPresent('.instance:nth-of-type(2)')
.click('.instance:nth-of-type(2)') .click('.instance:nth-of-type(2)')
.testFunction('retunValues1 - transact (not payable)', .testFunction('retunValues1 - transact (not payable)',
'0x79dc928d149d2ade02ab610a8ae290636222d034d4adce0bb08a68401e3d1f7f', '0x79dc928d149d2ade02ab610a8ae290636222d034d4adce0bb08a68401e3d1f7f',
@ -109,7 +109,7 @@ function testInputValues (browser, callback) {
contractHelper.testContracts(browser, 'inputValues.sol', sources[2]['browser/inputValues.sol'], ['test'], function () { contractHelper.testContracts(browser, 'inputValues.sol', sources[2]['browser/inputValues.sol'], ['test'], function () {
browser.click('.runView') browser.click('.runView')
.click('#runTabView button[class^="instanceButton"]') .click('#runTabView button[class^="instanceButton"]')
.pause(500) .waitForElementPresent('.instance:nth-of-type(2)')
.click('.instance:nth-of-type(2)') .click('.instance:nth-of-type(2)')
.testFunction('inputValue1 - transact (not payable)', .testFunction('inputValue1 - transact (not payable)',
'0x917a873d27d105213eaf5461e14780387ccceb66fed574f8432d1963917832ae', '0x917a873d27d105213eaf5461e14780387ccceb66fed574f8432d1963917832ae',

@ -32,6 +32,7 @@ module.exports = {
done() done()
}) })
}) })
.waitForElementPresent('.instance:nth-of-type(2)')
.click('.instance:nth-of-type(2)') .click('.instance:nth-of-type(2)')
.perform((client, done) => { .perform((client, done) => {
browser.clickFunction('set - transact (not payable)', {types: 'uint256 _p', values: '34'}) browser.clickFunction('set - transact (not payable)', {types: 'uint256 _p', values: '34'})

Loading…
Cancel
Save