fix test C-[a-m] tests.

This commit is contained in:
olumuyiwadad 2021-09-27 12:29:05 +05:30
parent 79fe3aacd7
commit fb0e9fac89
3 changed files with 4 additions and 4 deletions

View file

@ -75,7 +75,7 @@ Your new account is locked with a password. Please give a password. Do not forge
Passphrase: {{.InputLine "foobar"}} Passphrase: {{.InputLine "foobar"}}
Repeat passphrase: {{.InputLine "foobar"}} Repeat passphrase: {{.InputLine "foobar"}}
`) `)
XDC.ExpectRegexp(`Address: \{[0-9a-f]{40}\}\n`) XDC.ExpectRegexp(`Address: (xdc[0-9a-fA-F]{40})\n`)
} }
func TestAccountNewBadRepeat(t *testing.T) { func TestAccountNewBadRepeat(t *testing.T) {

View file

@ -31,7 +31,7 @@ import (
) )
const ( const (
ipcAPIs = "admin:1.0 debug:1.0 eth:1.0 miner:1.0 net:1.0 personal:1.0 XDPoS:1.0 rpc:1.0 XDCx:1.0 XDCxlending:1.0 txpool:1.0 web3:1.0" ipcAPIs = "XDCx:1.0 XDCxlending:1.0 XDPoS:1.0 admin:1.0 debug:1.0 eth:1.0 miner:1.0 net:1.0 personal:1.0 rpc:1.0 txpool:1.0 web3:1.0"
httpAPIs = "eth:1.0 net:1.0 rpc:1.0 web3:1.0" httpAPIs = "eth:1.0 net:1.0 rpc:1.0 web3:1.0"
) )

View file

@ -40,7 +40,7 @@ func TestMessageSignVerify(t *testing.T) {
Passphrase: {{.InputLine "foobar"}} Passphrase: {{.InputLine "foobar"}}
Repeat passphrase: {{.InputLine "foobar"}} Repeat passphrase: {{.InputLine "foobar"}}
`) `)
_, matches := generate.ExpectRegexp(`Address: (0x[0-9a-fA-F]{40})\n`) _, matches := generate.ExpectRegexp(`Address: (xdc[0-9a-fA-F]{40})\n`)
address := matches[1] address := matches[1]
generate.ExpectExit() generate.ExpectExit()
@ -59,7 +59,7 @@ Passphrase: {{.InputLine "foobar"}}
_, matches = verify.ExpectRegexp(` _, matches = verify.ExpectRegexp(`
Signature verification successful! Signature verification successful!
Recovered public key: [0-9a-f]+ Recovered public key: [0-9a-f]+
Recovered address: (0x[0-9a-fA-F]{40}) Recovered address: (xdc[0-9a-fA-F]{40})
`) `)
recovered := matches[1] recovered := matches[1]
verify.ExpectExit() verify.ExpectExit()