Skip to content

Instantly share code, notes, and snippets.

View Mandroide's full-sized avatar

Manuel Garcia Mandroide

View GitHub Profile
@JyotinderSingh
JyotinderSingh / oktaLogin.js
Created December 16, 2021 07:03 — forked from ndavis/oktaLogin.js
Cypress Custom Command for Okta Login
Cypress.Commands.add('loginOkta', () => {
const optionsSessionToken = {
method: 'POST',
url: Cypress.env('session_token_url'),
body: {
username: Cypress.env('username'),
password: Cypress.env('password'),
options: {
warnBeforePasswordExpired: 'true'
}