fix linting

pull/5778/head
yann300 1 week ago committed by Aniket
parent 50ff0f12d6
commit ca3ec72950
  1. 34
      libs/remix-debug/test/decoder/stateTests/revert-state-sub-call.ts

@ -76,7 +76,7 @@ function testRevertStateSubCall (st, privateKey, contractAddress, output, compil
tx: tx,
address: contractAddress
}, new StorageResolver({ web3 }), traceManager)
const stateVarsMyContract = stateDecoder.extractStateVariables('MyContract', output.sources)
stateDecoder.decodeState(stateVarsMyContract, storageViewerMyContract).then((result) => {
const contractAddressOtherContract = result['myCall'].value
@ -97,31 +97,31 @@ function testRevertStateSubCall (st, privateKey, contractAddress, output, compil
tx: tx,
address: contractAddressOtherContract
}, new StorageResolver({ web3 }), traceManager)
const stateVars = stateDecoder.extractStateVariables('OtherContract', output.sources)
stateDecoder.decodeState(stateVars, storageViewerOtherContract1).then((result) => {
// value should be set
st.equal(result['p'].value, '234')
stateDecoder.decodeState(stateVars, storageViewerOtherContract2).then((result) => {
// in the other sub call, the value is reverted
st.equal(result['p'].value, '0')
stateDecoder.decodeState(stateVars, storageViewerOtherContract3).then((result) => {
// and reset back to 234
st.equal(result['p'].value, '234')
cb()
}, (reason) => {
console.log('fail')
st.end(reason)
})
// in the other sub call, the value is reverted
st.equal(result['p'].value, '0')
stateDecoder.decodeState(stateVars, storageViewerOtherContract3).then((result) => {
// and reset back to 234
st.equal(result['p'].value, '234')
cb()
}, (reason) => {
console.log('fail')
st.end(reason)
})
}, (reason) => {
console.log('fail')
st.end(reason)
})
}, (reason) => {
console.log('fail')
st.end(reason)
})
})
}, (reason) => {
console.log('fail')
st.end(reason)
console.log('fail')
st.end(reason)
})
traceManager.resolveTrace(tx).then(() => {
debuggerEvent.trigger('newTraceLoaded', [traceManager.trace])

Loading…
Cancel
Save