From 66c017867f0fe39ec041dacb58cfb91e637edfb4 Mon Sep 17 00:00:00 2001 From: Oleh Bairak <118197764+olehbairak@users.noreply.github.com> Date: Fri, 2 Feb 2024 12:00:35 +0100 Subject: [PATCH] fix: update tests for removing duplicate portal links (#160) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit # What ❔ In the scope of this PR several changes to automation tests were performed. Based on the [PR](https://github.com/matter-labs/block-explorer/pull/159). Where Portal links were removed and replaced with one solid approach - to display link to Bridge as unified platform that we currently use. ## Why ❔ To have automation tests coverage up-to-date with recent changes and not to block ci/cd run with incorrect behavior for old link. ## Checklist - [ +] PR title corresponds to the body of PR (we generate changelog entries from PRs). - [ +] Tests for the changes have been added / updated. - [ -] Documentation comments have been added / updated. --- .../features/artifacts/artifactsSet1.feature | 49 +++++-------------- .../redirection/redirectionSet1.feature | 36 +++----------- 2 files changed, 20 insertions(+), 65 deletions(-) diff --git a/packages/app/tests/e2e/features/artifacts/artifactsSet1.feature b/packages/app/tests/e2e/features/artifacts/artifactsSet1.feature index 80d81ff0ca..f985c01e6b 100644 --- a/packages/app/tests/e2e/features/artifacts/artifactsSet1.feature +++ b/packages/app/tests/e2e/features/artifacts/artifactsSet1.feature @@ -4,53 +4,30 @@ Feature: Main Page Background: Given I am on main page - @id253 @featureEnv @testnet - Scenario Outline: Check the element "" in Tools section is available, clickable and have correct href - Given I click by text "Tools" - Given Element with "text" "" should be "visible" - When Element with "text" "" should be "clickable" - Then Element with "text" "" should have "" value - - Examples: - | Sub-Section | url | - | Smart Contract Verification | /contracts/verify | - #| Portal | https://goerli.staging-portal.zksync.dev/ | - - @id253 @featureEnv @mainnet - Scenario Outline: Check the element "" in Tools section is available, clickable and have correct href - Given I click by text "Tools" - Given Element with "text" "" should be "visible" - When Element with "text" "" should be "clickable" - Then Element with "text" "" should have "" value - Examples: - | Sub-Section | url | - | Smart Contract Verification | /contracts/verify | - #| Portal | https://staging-portal.zksync.dev/ | - - @id253:I @productionEnv @testnet - Scenario Outline: Check the element "" in Tools section is available, clickable and have correct href + @id253:I @featureEnv @testnetSmokeSuite @testnet + Scenario Outline: Check the element "" in Tools section is available, clickable and have correct href (Sepolia) Given I click by text "Tools" Given Element with "text" "" should be "visible" When Element with "text" "" should be "clickable" Then Element with "text" "" should have "" value Examples: - | Sub-Section | url | - | Smart Contract Verification | /contracts/verify | - #| Portal | https://goerli.portal.zksync.io/ | + | Sub-Section | url | + | Smart Contract Verification | /contracts/verify | + | Bridge | https://portal.zksync.io/bridge/?network=sepolia | - @id253:I @productionEnv @mainnet - Scenario Outline: Check the element "" in Tools section is available, clickable and have correct href + @id253:II @mainnet + Scenario Outline: Check the element "" in Tools section is available, clickable and have correct href (Mainnet) Given I click by text "Tools" Given Element with "text" "" should be "visible" When Element with "text" "" should be "clickable" Then Element with "text" "" should have "" value Examples: - | Sub-Section | url | - | Smart Contract Verification | /contracts/verify | - #| Portal | https://portal.zksync.io/ | + | Sub-Section | url | + | Smart Contract Verification | /contracts/verify | + | Bridge | https://portal.zksync.io/bridge/?network=mainnet | @id231 Scenario Outline: Check social networks icon "" is available, clickable and have correct href @@ -85,7 +62,7 @@ Feature: Main Page | zkSync Era Sepolia Testnet | network | | zkSync Era Goerli Testnet | network | | Goerli (Stage2) | network | - + @id254:II @productionEnv Scenario Outline: Check dropdown "" for "" and verify Given Set the "" value for "" switcher @@ -139,7 +116,7 @@ Feature: Main Page Given I go to page "/address/0x8f0F33583a56908F7F933cd6F0AaE382aC3fd8f6" Then Element with "id" "search" should be "visible" - @id209:I @testnet + @id209:I @testnet Scenario Outline: Verify Transaction table contains "" row Given I go to page "/tx/0xe7a91cc9b270d062328ef995e0ef67195a3703d43ce4e1d375f87d5c64e51981" When Table contains row with "" @@ -201,7 +178,7 @@ Feature: Main Page | Created | 2023-05-14 | - @id211 @testnet + @id211 @testnet Scenario Outline: Verify Contract info table contains "" row Given I go to page "/address/0x3e7676937A7E96CFB7616f255b9AD9FF47363D4b" Then Element with "text" "" should be "visible" diff --git a/packages/app/tests/e2e/features/redirection/redirectionSet1.feature b/packages/app/tests/e2e/features/redirection/redirectionSet1.feature index fc10256fbe..468f71feab 100644 --- a/packages/app/tests/e2e/features/redirection/redirectionSet1.feature +++ b/packages/app/tests/e2e/features/redirection/redirectionSet1.feature @@ -45,7 +45,7 @@ Feature: Redirection | Blocks | /blocks/ | | Transactions | /transactions/ | - @id253:II + @id253:I Scenario Outline: Verify redirection for "" in Tools menu Given I click by text "Tools " When I click by element with partial href "" and text "" @@ -56,26 +56,15 @@ Feature: Redirection | Smart Contract Verification | /contracts/verify | # | zkEVM Debugger | /tools/debugger | - @id253:III @featureEnv @testnet - Scenario Outline: Verify redirection for "" in Tools menu - Given I click by text "Tools " - When I click by element with partial href "" and text "" - Then New page have "" address - - Examples: - | Sub-Section | url | - #| Portal | https://goerli.staging-portal.zksync.dev/ | - - - @id253:IIII @productionEnv @testnet - Scenario Outline: Verify redirection for "" in Tools menu + @id253:III @featureEnv @testnetSmokeSuite @testnet + Scenario Outline: Verify redirection for "" in Tools menu (Sepolia) Given I click by text "Tools " When I click by element with partial href "" and text "" Then New page have "" address Examples: - | Sub-Section | url | redirect_url | - #| Portal | https://zksync.io/explore#bridges | https://goerli.portal.zksync.io | + | Sub-Section | url | redirect_url | + | Bridge | https://portal.zksync.io/bridge/?network=sepolia | https://portal.zksync.io/bridge/?network=sepolia | @id253:IV @featureEnv @mainnet Scenario Outline: Verify redirection for "" in Tools menu @@ -84,19 +73,8 @@ Feature: Redirection Then New page have "" address Examples: - | Sub-Section | url | - #| Portal | https://staging-portal.zksync.dev/ | - - - @id253:IV @productionEnv @mainnet - Scenario Outline: Verify redirection for "" in Tools menu - Given I click by text "Tools " - When I click by element with partial href "" and text "" - Then New page have "" address - - Examples: - | Sub-Section | url | redirect_url | - #| Portal | https://zksync.io/explore#bridges | https://portal.zksync.io | + | Sub-Section | url | + | Bridge | https://portal.zksync.io/bridge/?network=mainnet | #Account page @id259 @testnet