diff --git a/docs/DEVELOPMENT.md b/docs/DEVELOPMENT.md index 3a4be3346..b9e31d42e 100644 --- a/docs/DEVELOPMENT.md +++ b/docs/DEVELOPMENT.md @@ -31,13 +31,13 @@ You can preview the production build with `npm run preview`. ## 🌳 Environment -There are a few environment variables required for the app to function. You can find an overview under `.env.template`. You'll need access credentials for Pinata, Tenderly and a Gelato Relay API key for claiming projects. You'll also need to set up `PUBLIC_NETWORK`, as described right below. +There are a few environment variables required for the app to function. You can find an overview under `.env.template`. Youʼll need access credentials for Pinata, Tenderly and a Gelato Relay API key for claiming projects. Youʼll also need to set up `PUBLIC_NETWORK`, as described right below. ## 🔗 Chain Config -To run the app, you'll need to configure the `PUBLIC_NETWORK` environment variable. This should be the chainId of the chain you want to run the app for, and can currently be either 1, 5 or 11155111. The app will only allow connecting wallets that are set to this network, and all server-side requests will be made for this network's subgraph. +To run the app, youʼll need to configure the `PUBLIC_NETWORK` environment variable. This should be the chainId of the chain you want to run the app for, and can currently be either 1, 5 or 11155111. The app will only allow connecting wallets that are set to this network, and all server-side requests will be made for this network's subgraph. -For your convenience, we've deployed production mirrors of the app set to allow testnet connections: +For your convenience, weʼve deployed production mirrors of the app set to allow testnet connections: ```sh https://goerli.drips.network/ # PUBLIC_NETWORK set to 5 @@ -68,7 +68,7 @@ To get started, make sure you have Docker installed & running, ensure the app's npm run e2e ``` -This will build a production version of the app, and execute all E2E test suites. Each test suite itself will run `docker compose up` to start the E2E test environment (ipfs node, anvil testnet w/ Drips contracts, and Graph Node w/ Drips subgraph). On first run, you'll see `Pinging Graph Node…` being logged for an extended amount of time. On subsequent runs, this step will be a lot faster, because much of the E2E Docker environment is being cached. +This will build a production version of the app, and execute all E2E test suites. Each test suite itself will run `docker compose up` to start the E2E test environment (ipfs node, anvil testnet w/ Drips contracts, and Graph Node w/ Drips subgraph). On first run, youʼll see `Pinging Graph Node…` being logged for an extended amount of time. On subsequent runs, this step will be a lot faster, because much of the E2E Docker environment is being cached. **Important:** The local testnet is based on a static chain state which is copied into the testnet image from ./src/e2e-tests/docker/testnet/state. When a new version of contracts is released, this state needs to be updated. The subgraph is downloaded at image build time from the latest state of the `drips-subgraph` repo's `v2` branch. @@ -138,7 +138,7 @@ After doing this, the app will display the token within all token pickers. Alter #### `PUBLIC_TEST_MODE` and `playwrightAddress` -Unfortunately, two major differences in app logic for E2E tests couldn't be avoided: Firstly, the app uses a mock wallet store that connects to the local testnet instead of the real one, and IPFS access is mocked using localstorage. The logic checks for an env variable `PUBLIC_TEST_MODE` being true. The mock wallet store also checks for `window.playwrightAddress`, and initializes itself to be connected to that address. In order to make use of these adjustments, call `page.addInitScript` and set the two variables. +Unfortunately, two major differences in app logic for E2E tests couldnʼt be avoided: Firstly, the app uses a mock wallet store that connects to the local testnet instead of the real one, and IPFS access is mocked using localstorage. The logic checks for an env variable `PUBLIC_TEST_MODE` being true. The mock wallet store also checks for `window.playwrightAddress`, and initializes itself to be connected to that address. In order to make use of these adjustments, call `page.addInitScript` and set the two variables. ## 😱 Advanced diff --git a/src/e2e-tests/top-up-create-stream.e2e.test.ts b/src/e2e-tests/top-up-create-stream.e2e.test.ts index ccedc6c6b..8b450aec6 100644 --- a/src/e2e-tests/top-up-create-stream.e2e.test.ts +++ b/src/e2e-tests/top-up-create-stream.e2e.test.ts @@ -168,7 +168,6 @@ describe('app', async () => { it('displays the original users outgoing stream on their profile', async () => { await page.goto('http://127.0.0.1:3000/app/0x433220a86126eFe2b8C98a723E73eBAd2D0CbaDc'); - await expect(page.locator('text=↑ Outgoing')).toHaveCount(1); await expect(page.locator('text=E2E Test Stream')).toHaveCount(1); }); @@ -420,7 +419,7 @@ describe('app', async () => { await page.locator('div[data-testid="sidenav"] a:text("Drip List")').click(); await expect( - page.locator('text=Fund your dependencies by creating your Drip List'), + page.locator('text=Fund all your dependencies at once with a Drip List'), ).toHaveCount(1); }); @@ -536,7 +535,7 @@ describe('app', async () => { }); it('advances the flow', async () => { - await page.locator('button', { hasText: 'Confirm changes in wallet' }).click(); + await page.locator('button', { hasText: 'Confirm changes in your wallet' }).click(); await page.locator('button', { hasText: 'Got it' }).click(); }); @@ -551,9 +550,9 @@ describe('app', async () => { }); /* - The tests below are a bit tricky to implement because i wasn't able to find a way to get + The tests below are a bit tricky to implement because i wasnʼt able to find a way to get the vite preview server to pay attention to the PUBLIC_TEST_MODE env var. Without this being true, - it won't load the single drip list view, because that fetches data server-side, and without that env + it wonʼt load the single drip list view, because that fetches data server-side, and without that env var being set in the server just returns a 404. TODO: Figure out how to set PUBLIC_TEST_MODE to true in the vite `preview` server, then implement the diff --git a/src/lib/components/account-menu/account-menu.svelte b/src/lib/components/account-menu/account-menu.svelte index b0c9eb474..b22473135 100644 --- a/src/lib/components/account-menu/account-menu.svelte +++ b/src/lib/components/account-menu/account-menu.svelte @@ -1,8 +1,6 @@
{description}