diff --git a/apps/remix-ide-e2e/src/tests/pinned_contracts.test.ts b/apps/remix-ide-e2e/src/tests/pinned_contracts.test.ts index 83c48780c3..e13b482e4e 100644 --- a/apps/remix-ide-e2e/src/tests/pinned_contracts.test.ts +++ b/apps/remix-ide-e2e/src/tests/pinned_contracts.test.ts @@ -32,4 +32,30 @@ module.exports = { .assert.elementPresent('*[data-id="pinnedInstance0xd9145CCE52D386f254917e481eB44e9943F39138"]') .assert.hasClass('*[data-id="universalDappUiUdappUnpin"]', 'text-success') }, + 'Interact with pinned contract #group1': function (browser: NightwatchBrowser) { + browser + .click('*[data-id="universalDappUiTitleExpander0"]') + .assert.elementPresent('*[data-id="instanceContractBal"]') + .assert.elementPresent('*[data-id="instanceContractPinnedAt"]') + .assert.elementPresent('*[data-id="instanceContractFilePath"]') + .assert.textContains('*[data-id="instanceContractFilePath"]', 'default_workspace/contracts/1_Storage.sol') + .clickFunction('retrieve - call') + .testFunction('last', + { + to: 'Storage.retrieve() 0xd9145CCE52D386f254917e481eB44e9943F39138', + 'decoded output': { "0": "uint256: 0" } + }) + .clickFunction('store - transact (not payable)', { types: 'uint256 num', values: '35' }) + .testFunction('last', + { + status: '0x1 Transaction mined and execution succeed', + 'decoded input': { "uint256 num": "35" } + }) + .clickFunction('retrieve - call') + .testFunction('last', + { + to: 'Storage.retrieve() 0xd9145CCE52D386f254917e481eB44e9943F39138', + 'decoded output': { "0": "uint256: 35" } + }) + }, } \ No newline at end of file diff --git a/libs/remix-ui/run-tab/src/lib/components/universalDappUI.tsx b/libs/remix-ui/run-tab/src/lib/components/universalDappUI.tsx index c5cf200ddf..7a7496f178 100644 --- a/libs/remix-ui/run-tab/src/lib/components/universalDappUI.tsx +++ b/libs/remix-ui/run-tab/src/lib/components/universalDappUI.tsx @@ -311,7 +311,7 @@ export function UniversalDappUI(props: UdappProps) { {props.exEnvironment === 'injected' && {props.editInstance(props.instance)}}>} { props.isPinnedContract && props.instance.pinnedAt ? ( -