Skip to content

Commit

Permalink
1.17.0 (#895)
Browse files Browse the repository at this point in the history
* TW-487: APY of tzBTC from Yupana (#850)

* TW-459: [e2e] Import account by Mnemonic (#852)

* [e2e] Import account by Mnemonic

* env fix

* env fix

* env fix

* env fix

* env fix

* env fix

* TW-459: [e2e] Import account by Mnemonic. Refactor

* TW-459: [e2e] Import account by Mnemonic. Refactor

* TW-459: [e2e] Import account by Mnemonic. Refactor + CopyButton selector fix

---------

Co-authored-by: alex-seleznov <alex.seleznov@gmail.com>

* TW-486 Migrated from segment to Jitsu (#851)

* TW-486 Migrated from segment to Jitsu

* TW-486 Commented perform end-to-end tests

* TW-486 Fixed pipeline

* TW-486 Commented perform end-to-end tests

* TW-486 Fixed pipeline

* TW-486 Fixed pipeline

* TW-460: Import an account by private key (#855)

* merging TW-409-e2e-reveal-seed-phrase-and-private-key into development

* [e2e] Import an account by private key

* TW-498: Fix Everstake affiliate keys (#853)

* TW-498: Fix Everstake affiliate keys

* TW-498: Fix Everstake affiliate keys. Refactor

* TW-498: Fix Everstake affiliate keys. Env vars refactor

* TW-498: Fix Everstake affiliate keys. Env vars refactor

* TW-498: Fix Everstake affiliate keys. Refactor

* TW-487: APY of tzBTC from Yupana. Fix persisted links (#857)

* TW-487: APY of tzBTC from Yupana

* TW-487: APY of tzBTC from Yupana. Fix persisted links

* TW-452: Change places of 'Swap' & 'Withdraw' buttons (#858)

* TW-493: Sync Total Equity Value with displayed tokens (#859)

* TW-493: Sync Total Equity Value with displayed tokens

* TW-493: Sync Total Equity Value with displayed tokens. Fix tokens balance calculation

* TW-493: Sync Total Equity Value with displayed tokens. Refactor

* TW-493: Sync Total Equity Value with displayed tokens. Refactor

* TW-458: Create or restore an account (#856)

* create or restore account

* Create or restore an account

* common step refactor + env refactor

* browser context refactor

* browser context refactor + condition refactor

* TW-458: [e2e] Create-or-restore account. + Required env vars check at build

* TW-458: [e2e] Create-or-restore account. -- Required env vars check at runtime

---------

Co-authored-by: alex-seleznov <alex.seleznov@gmail.com>

* TW-489: Refactor event name (#860)

* refactor event name

* TW-489: [e2e] Refactor selectors' names. + SwapForm testIDs

* refactor event name + fix e2e BDD

* refactor event name + fix e2e BDD + dead code fix

* fix comment

* fix comment

---------

Co-authored-by: alex-seleznov <alex.seleznov@gmail.com>

* TW-497: e2e import account by watch only (#864)

* import account by watch-only

* import account by watch-only

* TW-505: Assets selector unified design (#861)

* TW-505: Assets selector unified design. Swap selectors

* TW-505: Assets selector unified design. Refactor

* TW-505: Assets selector unified design. Send selectors menus

* TW-505: Assets selector unified design. + Search to 'Send' asset field

* TW-505: Assets selector unified design. Fix 'Send' asset field

* TW-505: Assets selector unified design. Refactor

* TW-505: Assets selector unified design. Refactor

* TW-505: Assets selector unified design. Finish re-design

* TW-505: Assets selector unified design. + Search to selects in 'Settings' page

* TW-505: Assets selector unified design. Refactor

* TW-505: Assets selector unified design. Fix after tested

* TW-505: Assets selector unified design. + Currencies names in Utorg selector

* TW-505: Assets selector unified design. Refactor

* TW-505: Assets selector unified design. Refactor

* TW-505: Assets selector unified design. Refactor

* TW-505: Assets selector unified design. Refactor

* TW-505: Assets selector unified design. Refactor

* TW-358 Add cut decimals to value greater then 1000 (#867)

* TW-358 Add cut decimals to value grather then 1000

* TW-358 Add the correct balance formatter

* TW-358 Fix review

* TW-358 Fix review

---------

Co-authored-by: svyatoslavtt <stiven22235@gmail.com>

* TW-448 Added fetching balances from tzkt (#847)

* TW-448 Added fetching balances from tzkt

* TW-448 Improved balances

* TW-448 Fixed tokens loading

* TW-448 Fixed balance decimals

* TW-448 Fixed balance decimals

* TW-448 Fixed comment

* TW-448 Fixed tzks tokens metadata

* TW-448 Deleted console.logs

* TW-448 Fixed balances loading

* TW-448 Added balances store

* TW-448 Fixed comments

* TW-448 Fixed comments

* TW-448 Fixed loading balances

* TW-448 Fixed balances bugs

* TW-448 Fixed comments

* TW-557 - delegation on tezos forked blockchain (#866)

* change tzkt api base url for dcp

* fix api for t3l4nt mainnet

* TW-464: e2e-Unlock screen (#871)

* Unlock screen

* Magick number fix

* TW-463: e2e-Delegate + timeouts increased(pipeline fix) (#870)

* e2e-Delegate + timeouts increased(pipeline fix)

* e2e-Delegate + timeouts increased(pipeline fix)

* e2e-Delegate + timeouts increased(pipeline fix)

* e2e-Delegate + timeouts increased(pipeline fix)

* test pipeline

* test pipeline

* test pipeline

* test pipeline macos env

* test pipeline

* Delegate step refactor

* Delegate step refactor

* fix comments

* fix comments

* TW-560: Analytics. Track all events (#865)

* TW-560: Analytics. Track all events. Checkboxes

* TW-560: Analytics. Track all events. Refactor

* TW-560: Analytics. Track all events. Refactor

* TW-560: Analytics. Track all events. + Anchors analytics

* TW-560: Analytics. Track all events. Refactor

* TW-560: Analytics. Track all events. + Drop-down analytics

* TW-560: Analytics. Track all events. Refactor

* TW-560: Analytics. Track all events. Refactor

* TW-560: Analytics. Track all events. Refactor

* TW-560: Analytics. Track all events. Refactor

* TW-560: Analytics. Track all events. Refactor

* TW-560: Analytics. Track all events. Refactor

* TW-560: Analytics. Track all events. Refactor

* TW-560: Analytics. Track all events. + Analytics on tokens balances

* TW-560: Analytics. Track all events. Refactor

* TW-560: Analytics. Track all events. + ReduxStore.settings

* TW-560: Analytics. Track all events. Refactor

* TW-560: Analytics. Track all events. + Events

* TW-560: Analytics. Track all events. Fix e2e

* TW-560: Analytics. Track all events. ++[e2e]

* TW-560: Analytics. Track all events. Fix Jitsu SDK

* TW-560: Analytics. Track all events. Fix Jitsu SDK on MV2 + Fix analytics checkbox on 'Create Password' page

* TW-560: Analytics. Track all events. Refactor <HelpAndCommunity />

* TW-560: Analytics. Track all events. Jitsu. Fix with empty commit

* TW-560: Analytics. Track all events. [e2e] ++Timeouts

* TW-560: Analytics. Track all events. Jitsu. Fix with empty commit

* Tw 605 change the link for support (#876)

* TW-605: Change the link for support

* TW-605: Add constant for url

---------

Co-authored-by: svyatoslavtt <stiven22235@gmail.com>

* Tw 583 A/B testing for not delegate button (#872)

* TW-413: Add A/B testing for the delegate button

* TW-413: Add request for ab-testing to redux

* TW-413: Remove unused file

* TW-413: Fix imports

* TW-413: Add animation & track analytics

* e2e delegate apy button FIX

* TW-583: Fix review

* TW-583: Fix review

* TW-583: Fix review

* TW-583: Fix review

* TW-583: Add ab-testing request to unlock screen

---------

Co-authored-by: svyatoslavtt <stiven22235@gmail.com>
Co-authored-by: Vlad Novak <purch2442@gmail.com>

* TW-588: Block duration is 15 sec (#873)

* TW-588: Block duration is 15 sec

* TW-588: Block duration is 15 sec. BALANCES_SYNC_INTERVAL = BLOCK_DURATION

* TW-554: Add correct display of total balance in gas token (#877)

* TW-554: Add correct display of total balance in gas token

* TW-554: Remove unused code

* TW-554: Remove unused imports

---------

Co-authored-by: svyatoslavtt <stiven22235@gmail.com>

* TW-461: e2e send (#875)

* e2e-Delegate + timeouts increased(pipeline fix)

* e2e-Delegate + timeouts increased(pipeline fix)

* e2e-Delegate + timeouts increased(pipeline fix)

* e2e-Delegate + timeouts increased(pipeline fix)

* test pipeline

* test pipeline

* test pipeline

* test pipeline macos env

* test pipeline

* Delegate step refactor

* Delegate step refactor

* send first stage

* fix comments

* fix comments

* second send

* clearInput method added, send e2e completed

* hooks

* feature file fix

* puppeteer perfomance speed reduced

* TW-461: [e2e] Send. + Other selectors

---------

Co-authored-by: Alex <alex.seleznov@gmail.com>

* TW-453 Implement sorting tokens by USD equity (#874)

* TW-453 Implement sorting tokens by USD equity

* TW-453 Refactor sorting tokens for 'Send' page

* TW-453 Refactor useUsdToTokenRates function

* TW-534 Added partners promotion from 0xOptimal (#862)

* TW-362: Fix bug with network (#878)

* TW-455 Added route3 api to form (#854)

* TW-455 Added route3 api to form

* TW-445 Used route3 for swaps

* TW-455 Added 3route layout

* TW-455 Fixed deadcode

* TW-455 Finished 3route integration

* TW-455 deleted unnecessary files

* TW-455 Fixed added translations

* TW-455 Fixed pipeline

* TW-455 Added route3 contract to envs

* TW-455 fixed conflicts

* TW-455: 3-route integration. + env var to GitHub workflow

* TW-455 Moved route3 contract to constants

* TW-455 Deleted ROUTE3_CONTRACT from vars

* TW-455 Fixed comments

* TW-455 Added Auth token to .env

* TW-455 Commented e2e tests

* TW-455 Uncommented tests

* TW-455 Fixed rounding

* TW-455 Deleted uunecessary files

* TW-455 Fixed comments

* TW-455 Fixed .env.dist

* TW-455 Fixed manual build and release

* TW-455 Fixed bugs

* TW-455 Fixed comments

* TW-455 Added dex types

* TW-455 Fixed bugs after review

* TW-455 Fixed exports

* TW-455 Deleted unnecessary comment

* TW-455 Fixed kusd decimals

* TW-455 Fixed bugs after testing

* TW-455 deleted unneecessary file

* TW-455 Fixed bugs after testing

* TW-455 Moved loading swapParams to Epic

* TW-455 Fixed bugs after testing

* TW-455 Fixed toggle icon click

* TW-455 removed swap-router-sdk

* TW-455 Added isDefined helper

* TW-455 Fixed comment about undefined

* TW-455 Added tezos to deps

* TW-455 Fixed swap assets button

---------

Co-authored-by: alex-seleznov <alex.seleznov@gmail.com>

* TW-571 Fix errors not being properly reset in AddAsset form (#882)

* Remove legacy networks from default list; Add mumbainet (#885)

* TW-471: e2e change node (#886)

* change node

* change node

* timeouts added to every 'given'

* TW-623: e2e video-recorder setup (#883)

* e2e recorder (without fails)

* timeout increased

* timeout increased

* workflow fix

* minor fixes

---------

Co-authored-by: Alex <alex.seleznov@gmail.com>

* TW-641 The swap section is not sorted by dollar value (#892)

* sorting fixed

* useMemo update

Co-authored-by: Innokentiy Mazhara <keshan3262@gmail.com>

---------

Co-authored-by: Innokentiy Mazhara <keshan3262@gmail.com>

* TW-655 Don't render promotion in case it's empty (#890)

* TW-655 Don't render promotion in case it's empty

* TW-655 Handle broken images in promotions

* TW-655 Fix broken wallet one receiving unexpected response from optimal

* Tw 511 temple token (#884)

* TW-455 Added route3 api to form

* TW-445 Used route3 for swaps

* TW-455 Added 3route layout

* TW-455 Fixed deadcode

* TW-455 Finished 3route integration

* TW-455 deleted unnecessary files

* TW-455 Fixed added translations

* TW-455 Fixed pipeline

* TW-455 Added route3 contract to envs

* TW-455 fixed conflicts

* TW-455: 3-route integration. + env var to GitHub workflow

* TW-455 Moved route3 contract to constants

* TW-455 Deleted ROUTE3_CONTRACT from vars

* TW-455 Fixed comments

* TW-455 Added Auth token to .env

* TW-455 Commented e2e tests

* TW-455 Uncommented tests

* TW-455 Fixed rounding

* TW-455 Deleted uunecessary files

* TW-455 Fixed comments

* TW-455 Fixed .env.dist

* TW-455 Fixed manual build and release

* TW-455 Fixed bugs

* TW-455 Fixed comments

* TW-455 Added dex types

* TW-455 Fixed bugs after review

* TW-455 Fixed exports

* TW-455 Deleted unnecessary comment

* TW-455 Fixed kusd decimals

* TW-455 Fixed bugs after testing

* TW-455 deleted unneecessary file

* TW-455 Fixed bugs after testing

* TW-455 Moved loading swapParams to Epic

* TW-455 Fixed bugs after testing

* TW-455 Fixed toggle icon click

* TW-455 removed swap-router-sdk

* TW-455 Added isDefined helper

* TW-455 Fixed comment about undefined

* TW-455 Added tezos to deps

* TW-455 Fixed swap assets button

* TW-511 Added temple token as a fee

* TW-511 Fixed bug with swap Temple to Temple

* TW-511 Change fee calculation for SwapForm.tsx

* TW-511 Finished swap with first temple token

* TW-511 Added some refactoring

* TW-511 Fixed minimum received amount

* TW-511 added 10$ threshold

* TW-511 Added cashback field in swap form

* TW-511 Fixed swap params

* TW-511 Fixed comments

* TW-511 Fixed bugs after testing

* TW-511 Deleted console.log

* TW-511 Fixed bugs after testing

* TW-511 Fixed comments

---------

Co-authored-by: alex-seleznov <alex.seleznov@gmail.com>
Co-authored-by: Korney Vasilchenko <starkkor@gmail.com>

* TW-677 Change hardcoded token information (#893)

---------

Co-authored-by: Alex <alexseleznov@madfish.solutions>
Co-authored-by: Vlad <95026747+NovakVlad2424@users.noreply.github.com>
Co-authored-by: alex-seleznov <alex.seleznov@gmail.com>
Co-authored-by: Dmytro Herko <61412282+herkoss@users.noreply.github.com>
Co-authored-by: Svyatoslav Tyutyunnik <svyatoslavtt.work@gmail.com>
Co-authored-by: svyatoslavtt <stiven22235@gmail.com>
Co-authored-by: Aleks Razbeikov <58780063+Boltman92@users.noreply.github.com>
Co-authored-by: Vlad Novak <purch2442@gmail.com>
Co-authored-by: Innokentiy Mazhara <keshan3262@gmail.com>
Co-authored-by: Danyl Mishyn <35381314+lendihop@users.noreply.github.com>
  • Loading branch information
11 people committed May 9, 2023
1 parent 5b4ed72 commit 749eeb9
Show file tree
Hide file tree
Showing 453 changed files with 7,866 additions and 4,623 deletions.
5 changes: 4 additions & 1 deletion .env.dist
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
TEMPLE_WALLET_SEGMENT_WRITE_KEY=N1pFDJgp6ZJ6s5zfTM0cDhUWWhnE1TkS
TEMPLE_WALLET_JITSU_TRACKING_HOST=
TEMPLE_WALLET_JITSU_WRITE_KEY=

TEMPLE_WALLET_EXOLIX_API_KEY=
TEMPLE_WALLET_EVERSTAKE_API_KEY=
Expand All @@ -8,3 +9,5 @@ TEMPLE_WALLET_UTORG_SID=
TEMPLE_WALLET_API_URL=https://temple-api-mainnet.prod.templewallet.com
TEMPLE_WALLET_METADATA_API_URL=https://metadata-api-mainnet.prod.templewallet.com
TEMPLE_WALLET_DEXES_API_URL=wss://dexes-api-mainnet.prod.templewallet.com

TEMPLE_WALLET_ROUTE3_AUTH_TOKEN=
4 changes: 3 additions & 1 deletion .eslintrc
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,9 @@
"parser": "@typescript-eslint/parser",
"settings": {
"import/resolver": {
"typescript": {},
"typescript": {
"project": ["tsconfig.json", "e2e/tsconfig.json"]
},
"node": {
"extensions": [".d.ts"]
}
Expand Down
22 changes: 19 additions & 3 deletions .github/workflows/code-quality.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,17 +35,24 @@ jobs:
- name: Secrets setup
uses: ./.github/workflows/secrets-setup
with:
TEMPLE_WALLET_SEGMENT_WRITE_KEY: ${{ secrets.TEMPLE_WALLET_SEGMENT_WRITE_KEY }}
TEMPLE_WALLET_JITSU_TRACKING_HOST: ${{ vars.TEMPLE_WALLET_JITSU_TRACKING_HOST }}
TEMPLE_WALLET_JITSU_WRITE_KEY: ${{ vars.TEMPLE_WALLET_JITSU_WRITE_KEY }}
TEMPLE_WALLET_EXOLIX_API_KEY: ${{ secrets.TEMPLE_WALLET_EXOLIX_API_KEY }}
TEMPLE_WALLET_EVERSTAKE_API_KEY: ${{ secrets.TEMPLE_WALLET_EVERSTAKE_API_KEY }}
TEMPLE_WALLET_EVERSTAKE_LINK_ID: ${{ secrets.TEMPLE_WALLET_EVERSTAKE_LINK_ID }}
TEMPLE_WALLET_UTORG_SID: ${{ secrets.TEMPLE_WALLET_UTORG_SID }}
TEMPLE_WALLET_API_URL: ${{ vars.TEMPLE_WALLET_API_URL }}
TEMPLE_WALLET_METADATA_API_URL: ${{ vars.TEMPLE_WALLET_METADATA_API_URL }}
TEMPLE_WALLET_DEXES_API_URL: ${{ vars.TEMPLE_WALLET_DEXES_API_URL }}
DEFAULT_SEED_PHRASE: ${{ secrets.DEFAULT_SEED_PHRASE }}
DEFAULT_HD_ACCOUNT_SEED_PHRASE: ${{ secrets.DEFAULT_HD_ACCOUNT_SEED_PHRASE }}
DEFAULT_HD_ACCOUNT_FIRST_PRIVATE_KEY: ${{ secrets.DEFAULT_HD_ACCOUNT_FIRST_PRIVATE_KEY }}
DEFAULT_HD_ACCOUNT_SECOND_PRIVATE_KEY: ${{ secrets.DEFAULT_HD_ACCOUNT_SECOND_PRIVATE_KEY }}
DEFAULT_PASSWORD: ${{ secrets.DEFAULT_PASSWORD }}
DEFAULT_HD_ACCOUNT_PRIVATE_KEY: ${{ secrets.DEFAULT_HD_ACCOUNT_PRIVATE_KEY }}
IMPORTED_HD_ACCOUNT_SEED_PHRASE: ${{ secrets.IMPORTED_HD_ACCOUNT_SEED_PHRASE }}
IMPORTED_HD_ACCOUNT_FIRST_PRIVATE_KEY: ${{ secrets.IMPORTED_HD_ACCOUNT_FIRST_PRIVATE_KEY }}
TEMPLE_WALLET_ROUTE3_AUTH_TOKEN: ${{ vars.TEMPLE_WALLET_ROUTE3_AUTH_TOKEN }}
WATCH_ONLY_PUBLIC_KEY_HASH: ${{ secrets.WATCH_ONLY_PUBLIC_KEY_HASH }}
WATCH_ONLY_PUBLIC_KEY_HASH_SHORT_FORM: ${{ secrets.WATCH_ONLY_PUBLIC_KEY_HASH_SHORT_FORM }}

- name: Install dependencies and code quality check
uses: ./.github/workflows/code-quality-check
Expand All @@ -56,6 +63,15 @@ jobs:
- name: Perform end-to-end tests
uses: ./.github/workflows/e2e

- name: Upload E2E video to Slack
if: failure()
uses: adrey/slack-file-upload-action@master
with:
token: ${{ secrets.SLACK_E2E_VIDEO_UPLOADER_TOKEN }}
path: e2e/video-rep/test-runs.mp4
channel: temple-test-runs
initial_comment: <https://github.com/madfish-solutions/templewallet-extension/pull/${{ github.event.number }}|${{ github.event.pull_request.title }}> (Run <https://github.com/madfish-solutions/templewallet-extension/actions/runs/${{ github.run_id }}|№${{ github.run_number }}>)

- name: Upload artifact
uses: actions/upload-artifact@v2
with:
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/manual-builds.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,14 +41,16 @@ jobs:
- name: Secrets setup
uses: ./.github/workflows/secrets-setup
with:
TEMPLE_WALLET_SEGMENT_WRITE_KEY: ${{ secrets.TEMPLE_WALLET_SEGMENT_WRITE_KEY }}
TEMPLE_WALLET_JITSU_TRACKING_HOST: ${{ vars.TEMPLE_WALLET_JITSU_TRACKING_HOST }}
TEMPLE_WALLET_JITSU_WRITE_KEY: ${{ vars.TEMPLE_WALLET_JITSU_WRITE_KEY }}
TEMPLE_WALLET_EXOLIX_API_KEY: ${{ secrets.TEMPLE_WALLET_EXOLIX_API_KEY }}
TEMPLE_WALLET_EVERSTAKE_API_KEY: ${{ secrets.TEMPLE_WALLET_EVERSTAKE_API_KEY }}
TEMPLE_WALLET_EVERSTAKE_LINK_ID: ${{ secrets.TEMPLE_WALLET_EVERSTAKE_LINK_ID }}
TEMPLE_WALLET_UTORG_SID: ${{ secrets.TEMPLE_WALLET_UTORG_SID }}
TEMPLE_WALLET_API_URL: ${{ vars.TEMPLE_WALLET_API_URL }}
TEMPLE_WALLET_METADATA_API_URL: ${{ vars.TEMPLE_WALLET_METADATA_API_URL }}
TEMPLE_WALLET_DEXES_API_URL: ${{ vars.TEMPLE_WALLET_DEXES_API_URL }}
TEMPLE_WALLET_ROUTE3_AUTH_TOKEN: ${{ vars.TEMPLE_WALLET_ROUTE3_AUTH_TOKEN }}

- name: Install dependencies and code quality
uses: ./.github/workflows/code-quality-check
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,14 +36,16 @@ jobs:
- name: Secrets setup
uses: ./.github/workflows/secrets-setup
with:
TEMPLE_WALLET_SEGMENT_WRITE_KEY: ${{ secrets.TEMPLE_WALLET_SEGMENT_WRITE_KEY }}
TEMPLE_WALLET_JITSU_TRACKING_HOST: ${{ vars.TEMPLE_WALLET_JITSU_TRACKING_HOST }}
TEMPLE_WALLET_JITSU_WRITE_KEY: ${{ vars.TEMPLE_WALLET_JITSU_WRITE_KEY }}
TEMPLE_WALLET_EXOLIX_API_KEY: ${{ secrets.TEMPLE_WALLET_EXOLIX_API_KEY }}
TEMPLE_WALLET_EVERSTAKE_API_KEY: ${{ secrets.TEMPLE_WALLET_EVERSTAKE_API_KEY }}
TEMPLE_WALLET_EVERSTAKE_LINK_ID: ${{ secrets.TEMPLE_WALLET_EVERSTAKE_LINK_ID }}
TEMPLE_WALLET_UTORG_SID: ${{ secrets.TEMPLE_WALLET_UTORG_SID }}
TEMPLE_WALLET_API_URL: ${{ vars.TEMPLE_WALLET_API_URL }}
TEMPLE_WALLET_METADATA_API_URL: ${{ vars.TEMPLE_WALLET_METADATA_API_URL }}
TEMPLE_WALLET_DEXES_API_URL: ${{ vars.TEMPLE_WALLET_DEXES_API_URL }}
TEMPLE_WALLET_ROUTE3_AUTH_TOKEN: ${{ vars.TEMPLE_WALLET_ROUTE3_AUTH_TOKEN }}

- name: Install dependencies and code quality
uses: ./.github/workflows/code-quality-check
Expand Down
33 changes: 27 additions & 6 deletions .github/workflows/secrets-setup/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@ name: Secrets setup
description: Writes secrets

inputs:
TEMPLE_WALLET_SEGMENT_WRITE_KEY:
TEMPLE_WALLET_JITSU_TRACKING_HOST:
required: true
TEMPLE_WALLET_JITSU_WRITE_KEY:
required: true
TEMPLE_WALLET_EXOLIX_API_KEY:
required: false
Expand All @@ -19,11 +21,23 @@ inputs:
required: true
TEMPLE_WALLET_DEXES_API_URL:
required: true
DEFAULT_SEED_PHRASE:
DEFAULT_HD_ACCOUNT_SEED_PHRASE:
required: false
DEFAULT_HD_ACCOUNT_FIRST_PRIVATE_KEY:
required: false
DEFAULT_HD_ACCOUNT_SECOND_PRIVATE_KEY:
required: false
DEFAULT_PASSWORD:
required: false
IMPORTED_HD_ACCOUNT_SEED_PHRASE:
required: false
IMPORTED_HD_ACCOUNT_FIRST_PRIVATE_KEY:
required: false
TEMPLE_WALLET_ROUTE3_AUTH_TOKEN:
required: true
WATCH_ONLY_PUBLIC_KEY_HASH:
required: false
DEFAULT_HD_ACCOUNT_PRIVATE_KEY:
WATCH_ONLY_PUBLIC_KEY_HASH_SHORT_FORM:
required: false

runs:
Expand All @@ -33,7 +47,8 @@ runs:
shell: bash
run: |
cat << EOF > .env
TEMPLE_WALLET_SEGMENT_WRITE_KEY=${{ inputs.TEMPLE_WALLET_SEGMENT_WRITE_KEY }}
TEMPLE_WALLET_JITSU_TRACKING_HOST=${{ inputs.TEMPLE_WALLET_JITSU_TRACKING_HOST }}
TEMPLE_WALLET_JITSU_WRITE_KEY=${{ inputs.TEMPLE_WALLET_JITSU_WRITE_KEY }}
TEMPLE_WALLET_EXOLIX_API_KEY=${{ inputs.TEMPLE_WALLET_EXOLIX_API_KEY }}
TEMPLE_WALLET_EVERSTAKE_API_KEY=${{ inputs.TEMPLE_WALLET_EVERSTAKE_API_KEY }}
Expand All @@ -43,13 +58,19 @@ runs:
TEMPLE_WALLET_API_URL=${{ inputs.TEMPLE_WALLET_API_URL }}
TEMPLE_WALLET_METADATA_API_URL=${{ inputs.TEMPLE_WALLET_METADATA_API_URL }}
TEMPLE_WALLET_DEXES_API_URL=${{ inputs.TEMPLE_WALLET_DEXES_API_URL }}
TEMPLE_WALLET_ROUTE3_AUTH_TOKEN=${{ inputs.TEMPLE_WALLET_ROUTE3_AUTH_TOKEN }}
EOF
- name: Create e2e/.env file
shell: bash
run: |
cat << EOF > e2e/.env
DEFAULT_SEED_PHRASE=${{ inputs.DEFAULT_SEED_PHRASE }}
DEFAULT_HD_ACCOUNT_SEED_PHRASE=${{ inputs.DEFAULT_HD_ACCOUNT_SEED_PHRASE }}
DEFAULT_HD_ACCOUNT_FIRST_PRIVATE_KEY=${{ inputs.DEFAULT_HD_ACCOUNT_FIRST_PRIVATE_KEY }}
DEFAULT_HD_ACCOUNT_SECOND_PRIVATE_KEY=${{ inputs.DEFAULT_HD_ACCOUNT_SECOND_PRIVATE_KEY }}
DEFAULT_PASSWORD=${{ inputs.DEFAULT_PASSWORD }}
DEFAULT_HD_ACCOUNT_PRIVATE_KEY=${{ inputs.DEFAULT_HD_ACCOUNT_PRIVATE_KEY }}
IMPORTED_HD_ACCOUNT_SEED_PHRASE=${{ inputs.IMPORTED_HD_ACCOUNT_SEED_PHRASE }}
IMPORTED_HD_ACCOUNT_FIRST_PRIVATE_KEY=${{ inputs.IMPORTED_HD_ACCOUNT_FIRST_PRIVATE_KEY }}
WATCH_ONLY_PUBLIC_KEY_HASH=${{ inputs.WATCH_ONLY_PUBLIC_KEY_HASH }}
WATCH_ONLY_PUBLIC_KEY_HASH_SHORT_FORM=${{ inputs.WATCH_ONLY_PUBLIC_KEY_HASH_SHORT_FORM }}
EOF
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -42,3 +42,6 @@ DerivedData
*.hmap
*.ipa
*.xcuserstate

#e2e
video-rep
12 changes: 10 additions & 2 deletions e2e/.env.dist
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
DEFAULT_SEED_PHRASE=
DEFAULT_HD_ACCOUNT_SEED_PHRASE=
DEFAULT_HD_ACCOUNT_FIRST_PRIVATE_KEY=
DEFAULT_HD_ACCOUNT_SECOND_PRIVATE_KEY=

DEFAULT_PASSWORD=
DEFAULT_HD_ACCOUNT_PRIVATE_KEY=

IMPORTED_HD_ACCOUNT_SEED_PHRASE=
IMPORTED_HD_ACCOUNT_FIRST_PRIVATE_KEY=

WATCH_ONLY_PUBLIC_KEY_HASH=
WATCH_ONLY_PUBLIC_KEY_HASH_SHORT_FORM=
11 changes: 6 additions & 5 deletions e2e/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,18 +4,19 @@
"private": true,
"license": "MIT",
"scripts": {
"start": "./node_modules/.bin/cucumber-js",
"start": "./node_modules/.bin/cucumber-js --fail-fast",
"start:dev": "yarn start --tags @dev",
"test": "yarn start --exit",
"ts": "tsc --pretty"
},
"dependencies": {
"@cucumber/cucumber": "^8.7.0",
"@types/chai": "^4.3.4",
"async-retry": "^1.3.3",
"puppeteer": "^19.4.0",
"ts-node": "^10.9.1",
"chai": "^4.3.7",
"dotenv": "^16.0.3",
"@types/chai": "^4.3.4",
"chai": "^4.3.7"
"puppeteer-screen-recorder": "^2.1.2",
"puppeteer": "^19.4.0",
"ts-node": "^10.9.1"
}
}
22 changes: 7 additions & 15 deletions e2e/src/classes/browser-context.class.ts
Original file line number Diff line number Diff line change
@@ -1,25 +1,17 @@
import { Browser, Page } from 'puppeteer';
import { PuppeteerScreenRecorder } from 'puppeteer-screen-recorder';

import { getEnv } from '../utils/env.utils';

const defaultSeedPhrase = getEnv('DEFAULT_SEED_PHRASE');
const defaultPassword = getEnv('DEFAULT_PASSWORD');
const defaultPrivateKey = getEnv('DEFAULT_HD_ACCOUNT_PRIVATE_KEY');

if (!defaultSeedPhrase) throw new Error('process.env.DEFAULT_SEED_PHRASE not found.');
if (!defaultPassword) throw new Error('process.env.DEFAULT_PASSWORD not found.');
if (!defaultPrivateKey) throw new Error('process.env.DEFAULT_PASSWORD not found.');
import { envVars } from '../utils/env.utils';

export class BrowserContext {
public static EXTENSION_ID: string;
public static browser: Browser;
public static page: Page;
public static seedPhrase = defaultSeedPhrase;
public static password = defaultPassword;
public static privateKey = defaultPrivateKey;
public static seedPhrase = envVars.DEFAULT_HD_ACCOUNT_SEED_PHRASE;
public static password = envVars.DEFAULT_PASSWORD;
public static recorder: PuppeteerScreenRecorder;
public static resetPrivates = () => {
BrowserContext.seedPhrase = defaultSeedPhrase;
BrowserContext.password = defaultPassword;
BrowserContext.privateKey = defaultPrivateKey;
BrowserContext.seedPhrase = envVars.DEFAULT_HD_ACCOUNT_SEED_PHRASE;
BrowserContext.password = envVars.DEFAULT_PASSWORD;
};
}
10 changes: 10 additions & 0 deletions e2e/src/features/change-node.feature
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
Feature: Change node
@dev
Scenario: As a user, i'd like to change node
Given I have imported an existing account
And I am on the Header page

And I press Selected Network Button on the Network Select page
And I select Ghostnet Testnet node in the networks drop-down list on the Header page

Then I check that Ghostnet Testnet node is selected correctly
16 changes: 8 additions & 8 deletions e2e/src/features/create-new-wallet.feature
Original file line number Diff line number Diff line change
@@ -1,25 +1,25 @@
Feature: Create a new wallet
@dev

Scenario: As a user, i'd like to create a new wallet
Given I am on the Welcome page
And I press Create New Wallet button on the Welcome page

And I am on the NewSeedBackup page
And I press Protected Mask on the NewSeedBackup page
And I press Protected Mask on the New Seed Back-up page
And I save my mnemonic
And I press I made Seed Phrase Backup Check Box on the NewSeedBackup page
And I press Next Button on the NewSeedBackup page
And I press I made Seed Phrase Backup Check Box on the New Seed Back-up page
And I press Next Button on the New Seed Back-up page

And I am on the VerifyMnemonic page
And I verify my mnemonic
And I press Next Button on the NewSeedVerify page
And I press Next Button on the New Seed Verify page

And I am on the SetWallet page
And I enter password into Password Field on the Register Form page
And I enter password into Repeat Password Field on the Register Form page
And I enter defaultPassword into Password Field on the Register Form page
And I enter defaultPassword into Repeat Password Field on the Register Form page
And I press Skip Onboarding Checkbox on the Register Form page
And I press Accept Terms Checkbox on the Register Form page
And I press Create Button on the Register Form page

Then I am on the Header page
Then I am on the Home page

17 changes: 17 additions & 0 deletions e2e/src/features/create-or-restore-an-account.feature
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
Feature: Create or restore an account

Scenario: As a user, I'd like to create or restore an account
Given I have imported an existing account

And I press Account Icon on the Header page
And I am on the AccountsDropdown page

And I press Create Or Restore Account Button on the Account Drop-down page
And I am on the CreateOrRestoreAnAccount page

And I press Create Or Restore Button on the Create Account page
And I am on the Home page

Then I reveal a private key and compare with defaultSecondPrivateKey


20 changes: 20 additions & 0 deletions e2e/src/features/delegate.feature
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
Feature: Delegate

Scenario: As a user, i'd like to re-delegate TEZ to a baker
Given I have imported an existing account
And I press Asset Item Apy Button on the Assets page

And I am on the DelegateTab page
And I check who the delegated baker is
And I press Re-Delegate Button on the Baking Section page

And I am on the DelegateForm page
And I enter bakerAddress into Baker Input on the Delegate Form page
And I press Baker Item Delegate Button on the Delegate Form page

And I am on the InternalConfirmation page
And I press Confirm Button on the Internal Confirmation page

And I am on the OperationStatusAlert page

Then I'm waiting for 'success ✓' operation status
18 changes: 18 additions & 0 deletions e2e/src/features/import-account-by-mnemonic.feature
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
Feature: Import Account by Mnemonic
@dev
Scenario: As a user, I'd like to import account by mnemonic
Given I have imported an existing account

And I press Account Icon on the Header page
And I am on the AccountsDropdown page

And I press Import Account Button on the Account Drop-down page
And I am on the ImportAccountTab page

And I select Mnemonic tab
And I am on the ImportAccountMnemonic page

And I enter second mnemonic
And I press Mnemonic Import Button on the Import Account(Mnemonic) page

Then I reveal a private key and compare with importedFirstPrivateKey
17 changes: 17 additions & 0 deletions e2e/src/features/import-account-by-private-key.feature
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
Feature: Import Account by Private Key
Scenario: As a user, I'd like to import account by private key
Given I have imported an existing account

And I press Account Icon on the Header page
And I am on the AccountsDropdown page

And I press Import Account Button on the Account Drop-down page
And I am on the ImportAccountTab page

And I select Private Key tab
And I am on the ImportAccountPrivateKey page

And I enter importedFirstPrivateKey into Private Key Input on the Import Account(Private Key) page
And I press Private Key Import Button on the Import Account(Private Key) page

Then I reveal a private key and compare with importedFirstPrivateKey
18 changes: 18 additions & 0 deletions e2e/src/features/import-account-by-public-key.feature
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
Feature: Import an account by public key (Watch-only)

Scenario: As a user, I'd like to import an account by public key
Given I have imported an existing account

And I press Account Icon on the Header page
And I am on the AccountsDropdown page

And I press Import Account Button on the Account Drop-down page
And I am on the ImportAccountTab page

And I select Watch-only tab
And I am on the ImportAccountWatchOnly page

And I enter watchOnlyPublicKey into Watch Only Input on the Import Account(Watch-Only) page
And I press Watch Only Import Button on the Import Account(Watch-Only) page

Then I compare my Watch-only Public hash with imported account
Loading

0 comments on commit 749eeb9

Please sign in to comment.