Commit ac8e64d6 authored by tom's avatar tom

add menu nav item

parent 6ccad0bf
...@@ -19,3 +19,4 @@ NEXT_PUBLIC_IS_TESTNET=true ...@@ -19,3 +19,4 @@ NEXT_PUBLIC_IS_TESTNET=true
# api config # api config
NEXT_PUBLIC_API_HOST=blockscout.com NEXT_PUBLIC_API_HOST=blockscout.com
NEXT_PUBLIC_STATS_API_HOST=https://stats-test.aws-k8s.blockscout.com NEXT_PUBLIC_STATS_API_HOST=https://stats-test.aws-k8s.blockscout.com
NEXT_PUBLIC_CONTRACT_INFO_API_HOST=https://contracts-info-test.aws-k8s.blockscout.com
...@@ -223,13 +223,13 @@ export default function useNavItems(): ReturnType { ...@@ -223,13 +223,13 @@ export default function useNavItems(): ReturnType {
isActive: pathname === '/account/custom_abi', isActive: pathname === '/account/custom_abi',
isNewUi: true, isNewUi: true,
}, },
// appConfig.contractInfoApi.endpoint && { appConfig.contractInfoApi.endpoint && {
// text: 'Verified addresses', text: 'Verified addrs',
// nextRoute: { pathname: '/account/verified_addresses' as const }, nextRoute: { pathname: '/account/verified_addresses' as const },
// icon: verifiedIcon, icon: verifiedIcon,
// isActive: pathname === '/account/verified_addresses', isActive: pathname === '/account/verified_addresses',
// isNewUi: true, isNewUi: true,
// }, },
].filter(Boolean); ].filter(Boolean);
const profileItem = { const profileItem = {
......
import type { test } from '@playwright/experimental-ct-react'; import type { test } from '@playwright/experimental-ct-react';
import type { PlaywrightWorkerArgs } from '@playwright/test';
interface Env { interface Env {
name: string; name: string;
...@@ -6,18 +7,22 @@ interface Env { ...@@ -6,18 +7,22 @@ interface Env {
} }
// keep in mind that all passed variables here should be present in env config files (.env.pw or .env.poa) // keep in mind that all passed variables here should be present in env config files (.env.pw or .env.poa)
export default function createContextWithEnvs(envs: Array<Env>): Parameters<typeof test.extend>[0]['context'] { export default function contextWithEnvsFixture(envs: Array<Env>): Parameters<typeof test.extend>[0]['context'] {
return async({ browser }, use) => { return async({ browser }, use) => {
const context = await browser.newContext({ const context = await createContextWithEnvs(browser, envs);
storageState: {
origins: [
{ origin: 'http://localhost:3100', localStorage: envs },
],
cookies: [],
},
});
await use(context); await use(context);
await context.close(); await context.close();
}; };
} }
export function createContextWithEnvs(browser: PlaywrightWorkerArgs['browser'], envs: Array<Env>) {
return browser.newContext({
storageState: {
origins: [
{ origin: 'http://localhost:3100', localStorage: envs },
],
cookies: [],
},
});
}
...@@ -32,7 +32,7 @@ test('no auth +@desktop-xl +@dark-mode-xl', async({ mount }) => { ...@@ -32,7 +32,7 @@ test('no auth +@desktop-xl +@dark-mode-xl', async({ mount }) => {
test.describe('auth', () => { test.describe('auth', () => {
const extendedTest = test.extend({ const extendedTest = test.extend({
context: ({ context }, use) => { context: async({ context }, use) => {
authFixture(context); authFixture(context);
use(context); use(context);
}, },
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment