Skip to content

Instantly share code, notes, and snippets.

@mandemeskel
Created March 11, 2024 07:29
Show Gist options
  • Save mandemeskel/36d163c83e8eea8906d747b5db5b826b to your computer and use it in GitHub Desktop.
Save mandemeskel/36d163c83e8eea8906d747b5db5b826b to your computer and use it in GitHub Desktop.
Retool, Setup File for Loging in on Test Start
import { test as setup} from '@playwright/test'
import { LoginTapi } from '../tapis/login_tapi'
const authFile = './playwright/.auth/user.json'
setup('saves login state', async ({ page }) => {
const login_tapi = new LoginTapi(page)
await login_tapi.login()
await page.context().storageState({ path: authFile })
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment