Skip to content

Commit

Permalink
test: switch and fix test on sepolia
Browse files Browse the repository at this point in the history
  • Loading branch information
pcheremu committed Dec 7, 2023
1 parent 4bf3d32 commit 9fc5a8b
Show file tree
Hide file tree
Showing 8 changed files with 27 additions and 20 deletions.
3 changes: 2 additions & 1 deletion .github/workflows/app-deploy-feature-branch.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,13 +66,14 @@ jobs:

mainnet:
needs: build
name: Feature Env, Mainnet+
name: Feature on Mainnet + Sepolia
uses: ./.github/workflows/app-e2e.yml
secrets: inherit
permissions:
contents: read
with:
targetUrl: ${{ needs.build.outputs.dappUrl }}
testnet_network_value_for_e2e: "/?network=sepolia"
default_network_value_for_e2e: "/?network=mainnet"
publish_to_allure: true
environmentTags: "and not @productionEnv"
3 changes: 2 additions & 1 deletion .github/workflows/app-deploy-preview.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,13 +63,14 @@ jobs:
mainnet:
needs: deploy
name: Staging Env, Mainnet+
name: Staging on Mainnet + Sepolia
uses: ./.github/workflows/app-e2e.yml
secrets: inherit
permissions:
contents: read
with:
targetUrl: ${{ needs.deploy.outputs.dappUrl }}
testnet_network_value_for_e2e: "/?network=sepolia"
default_network_value_for_e2e: "/?network=mainnet"
publish_to_allure: true
environmentTags: "and not @featureEnv"
6 changes: 5 additions & 1 deletion .github/workflows/app-e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,10 @@ on:
type: string
default: '/?network=mainnet'
required: true
testnet_network_value_for_e2e:
type: string
default: '/?network=sepolia'
required: true
publish_to_allure: #Here we define the variable that can be overwritten by caller workflow
type: boolean
description: "Publish test results to allure"
Expand Down Expand Up @@ -100,7 +104,7 @@ jobs:
echo "Run tests"
if [ "${{ matrix.tags }}" = "@testnetSmokeSuite" ]; then
echo "Run in testnetSmokeSuite only"
E2ENETWORK='/?network=sepolia' npx cucumber-js --tags "${{ matrix.tags }} ${{ inputs.environmentTags }} and not @mainnet"
E2ENETWORK='${{ inputs.testnet_network_value_for_e2e }}' npx cucumber-js --tags "${{ matrix.tags }} ${{ inputs.environmentTags }} and not @mainnet"
else
echo "Run in mainnet"
E2ENETWORK='${{ inputs.default_network_value_for_e2e }}' npx cucumber-js --tags "${{ matrix.tags }} ${{ inputs.environmentTags }} and not @testnet"
Expand Down
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ lerna-debug.log*
!.vscode/extensions.json

# Allure
/allure-results/
**allure-results/

# App hyperchain config
hyperchain.config.json
12 changes: 6 additions & 6 deletions packages/app/tests/e2e/features/artifacts/artifactsSet3.feature
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ Feature: Main Page
# When I click by text "Show more transactions ->"
Then Element with "text" "self" should be "visible"

@id580 @id578 @id619 @testnet @testnetSmokeSuite
@id580 @id578 @id619 @testnet
Scenario Outline: Verify label "<label name>" for method column on Contract page
Given I go to page "<Page>"
Then Column with "Method" name includes "<label name>" cell
Expand All @@ -142,7 +142,7 @@ Feature: Main Page

@id258 @testnet @testnetSmokeSuite
Scenario Outline: Check data type dropdown for "<Row>" and select "<Value>"
Given I go to page "/tx/0x4f7406f5565d875ce1a2ebb7c83f582e9795294ad57276eae3909b59537ab051"
Given I go to page "/tx/0x4dca9c536124e5e2b29af17d075c3e55d15f119acf5f3327c9fdb1a3ffeab427"
When I select "Logs" tab on "Transaction" page
When I click on datatype dropdown of "<Row>" row
When I click by text "<Value>"
Expand All @@ -153,11 +153,11 @@ Feature: Main Page
| Topics | Hex |
| Topics | Number |
| Topics | Text |
| Topics | Address |
| Topics | Addres |
| Data | Hex |
| Data | Number |
| Data | Text |
| Data | Address |
| Data | Addres |

@id258 @mainnet
Scenario Outline: Check data type dropdown for "<Row>" and select "<Value>"
Expand Down Expand Up @@ -189,13 +189,13 @@ Feature: Main Page

@id588 @testnet @testnetSmokeSuite
Scenario: Check Processed status component for Transaction page
Given I go to page "/tx/0x51cef3cdc8237635c6151b664c1925281766fabe2fa3d60e63f1369829c2f881"
Given I go to page "/tx/0x4dca9c536124e5e2b29af17d075c3e55d15f119acf5f3327c9fdb1a3ffeab427"
Then Verify the badge with "Processed" status is visible
Then Verify the badge with "Executed" status is visible
Then Element with "text" "Executed" should be "visible"
# Then Status component color with "Executed" status should be "green"

@id589 @testnet @testnetSmokeSuite
@id589 @testnet
Scenario: Check Failed status component for Transaction page
Given I go to page "/tx/0xb556d6cd77cf37002c668156b0ea7a1c18050decc1c99a67d6aa3b214647d2ae"
Then Verify the badge with "Failed" status is visible
Expand Down
3 changes: 2 additions & 1 deletion packages/app/tests/e2e/features/copying.feature
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,8 @@ Feature: Copying
# And Element with "text" "Copied!" should be "visible"
# Then Clipboard value is not empty

@id275 @testnet @testnetSmokeSuite
#@testnetSmokeSuite no tokens in tokenlist
@id275 @testnet
Scenario Outline: Check "<Row>" hashes copying for Tokens page
Given I go to page "/tokenlist"
When I click on the copy button with "<Row>" row on "Tokens" page
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ Feature: Redirection

@id242:I @testnet @testnetSmokeSuite
Scenario Outline: Verify redirection from Contracts page after "<Artifact type>" click
Given I go to page "/address/0xAB2e93b557ef5FD04ABc6f57De6a1D1DE18924c4"
Given I go to page "/address/0x000000000000000000000000000000000000800A"
When I click on the first "<Artifact type>" link
Given Page with part address "<url>" includes ID result

Expand Down Expand Up @@ -91,7 +91,7 @@ Feature: Redirection
#Transaction page 241 - navigation, 553 - redirection
@id241 @id553 @id339 @id340 @testnet @testnetSmokeSuite
Scenario Outline: Verify redirection from Transaction page after "<Artifact type>" click
Given I go to page "/tx/0x6fc015405255af17fb38f5a1408557f5f00d094e07a2f8f6af933a889d9a3330"
Given I go to page "/tx/0x095ba0e946b09767085c7ddfb0f9ff36fab230fc819b56d41185a3033de27bea"
When I click on the first "<Artifact type>" link
Given Page with part address "<url>" includes ID result

Expand Down Expand Up @@ -132,8 +132,8 @@ Feature: Redirection
| Fee | /address/ |


#Tokens page
@id250 @testnetSmokeSuite
#Tokens page @testnetSmokeSuite
@id250
Scenario Outline: Verify redirection from Tokens page after "<Artifact type>" click
Given I go to page "/tokenlist/"
When I click on the first "<Artifact type>" link
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ Feature: Redirection

Examples:
| Block Number | Artifact type | url |
| 1003 | from address | /address/ |
| 1003 | to address | /address/ |
| 100 | from address | /address/ |
| 100 | to address | /address/ |

@id368:I @mainnet
Scenario: Verify redirection from Block page L1 addresses to etherscan after address click
Expand All @@ -25,8 +25,8 @@ Feature: Redirection

Examples:
| Block Number | Artifact type | url |
| 1003 | from address | /address/ |
| 1003 | to address | /address/ |
| 100 | from address | /address/ |
| 100 | to address | /address/ |

#Main Page - Transaction page
@id338 @testnetSmokeSuite
Expand All @@ -43,7 +43,7 @@ Feature: Redirection
#369 Contract page - Pages - Redirection
@id369 @testnet @testnetSmokeSuite
Scenario: Verify contract link on the Contacts page
Given I go to page "/address/0x0BfcE1D53451B4a8175DD94e6e029F7d8a701e9c"
Given I go to page "/address/0xed7175341f123f7718aBaCF1702d6980CFc08784"
When I click on the first "from address" link
Given Page with part address "/address/" includes ID result

Expand Down

0 comments on commit 9fc5a8b

Please sign in to comment.