Switch signature-request e2e tests to using ganache (#7859)

The signature request e2e tests were previously using ropsten. This
expectation was even hard-coded into the test contract dapp.

Instead the contract-dapp has been updated to use the current `chainId`
when calling `signTypedData` (falling back to the `networkId` if
`chainId` is not set). The fixture used by `signature-request` has been
updated to use ganache.
feature/default_network_editable
Mark Stacey 5 years ago committed by GitHub
parent 1728d9a5aa
commit 3a2c81d8bc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 5
      test/e2e/contract-test/contract.js
  2. 4
      test/e2e/fixtures/imported-account/state.json

@ -269,6 +269,9 @@ const initialize = () => {
} }
signTypedData.addEventListener('click', () => { signTypedData.addEventListener('click', () => {
const networkId = parseInt(networkDiv.innerHTML)
const chainId = parseInt(chainIdDiv.innerHTML) || networkId
const typedData = { const typedData = {
types: { types: {
EIP712Domain: [ EIP712Domain: [
@ -291,7 +294,7 @@ const initialize = () => {
domain: { domain: {
name: 'Ether Mail', name: 'Ether Mail',
version: '1', version: '1',
chainId: 3, chainId,
verifyingContract: '0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC', verifyingContract: '0xCcCCccccCCCCcCCCCCCcCcCccCcCCCcCcccccccC',
}, },
message: { message: {

@ -27,12 +27,12 @@
"vault": "{\"data\":\"s6TpYjlUNsn7ifhEFTkuDGBUM1GyOlPrim7JSjtfIxgTt8/6MiXgiR/CtFfR4dWW2xhq85/NGIBYEeWrZThGdKGarBzeIqBfLFhw9n509jprzJ0zc2Rf+9HVFGLw+xxC4xPxgCS0IIWeAJQ+XtGcHmn0UZXriXm8Ja4kdlow6SWinB7sr/WM3R0+frYs4WgllkwggDf2/Tv6VHygvLnhtzp6hIJFyTjh+l/KnyJTyZW1TkZhDaNDzX3SCOHT\",\"iv\":\"FbeHDAW5afeWNORfNJBR0Q==\",\"salt\":\"TxZ+WbCW6891C9LK/hbMAoUsSEW1E8pyGLVBU6x5KR8=\"}" "vault": "{\"data\":\"s6TpYjlUNsn7ifhEFTkuDGBUM1GyOlPrim7JSjtfIxgTt8/6MiXgiR/CtFfR4dWW2xhq85/NGIBYEeWrZThGdKGarBzeIqBfLFhw9n509jprzJ0zc2Rf+9HVFGLw+xxC4xPxgCS0IIWeAJQ+XtGcHmn0UZXriXm8Ja4kdlow6SWinB7sr/WM3R0+frYs4WgllkwggDf2/Tv6VHygvLnhtzp6hIJFyTjh+l/KnyJTyZW1TkZhDaNDzX3SCOHT\",\"iv\":\"FbeHDAW5afeWNORfNJBR0Q==\",\"salt\":\"TxZ+WbCW6891C9LK/hbMAoUsSEW1E8pyGLVBU6x5KR8=\"}"
}, },
"NetworkController": { "NetworkController": {
"network": "3", "network": "5777",
"provider": { "provider": {
"nickname": "", "nickname": "",
"rpcTarget": "", "rpcTarget": "",
"ticker": "ETH", "ticker": "ETH",
"type": "ropsten" "type": "localhost"
}, },
"settings": { "settings": {
"ticker": "ETH" "ticker": "ETH"

Loading…
Cancel
Save