diff --git a/selenium/README.md b/selenium/README.md index 6bec54a14fa..c667f8ceef1 100644 --- a/selenium/README.md +++ b/selenium/README.md @@ -236,3 +236,8 @@ following command: MOCHA_DOCKER_FILE=\location\of\my\Dockerfile ./run-suites.sh ``` +## Issues deploying UAA + +If you are not able to successfully run any test case that depends on UAA +because UAA fails to start, make sure you are using VZ emulation in your docker +engine. Without VZ emulation, the uaa docker container cannot start. diff --git a/selenium/test/oauth/with-idp-initiated/happy-login.js b/selenium/test/oauth/with-idp-initiated/happy-login.js index 6ec05337383..eb639010b99 100644 --- a/selenium/test/oauth/with-idp-initiated/happy-login.js +++ b/selenium/test/oauth/with-idp-initiated/happy-login.js @@ -11,8 +11,12 @@ describe('A user with a JWT token', function () { let overview let captureScreen let fakePortal - + let username + let password + before(async function () { + username = process.env.MGT_CLIENT_ID_FOR_IDP_INITIATED || 'rabbit_idp_user' + password = process.env.MGT_CLIENT_SECRET_FOR_IDP_INITIATED || 'rabbit_idp_user' driver = buildDriver() overview = new OverviewPage(driver) captureScreen = captureScreensFor(driver, __filename) @@ -20,13 +24,13 @@ describe('A user with a JWT token', function () { }) it('can log in presenting the token to the /login URL via fakeportal', async function () { - await fakePortal.goToHome("rabbit_idp_user", "rabbit_idp_user") + await fakePortal.goToHome(username, password) if (!await fakePortal.isLoaded()) { throw new Error('Failed to load fakePortal') } await fakePortal.login() await overview.isLoaded() - assert.equal(await overview.getUser(), 'User rabbit_idp_user') + assert.equal(await overview.getUser(), 'User ' + username) }) after(async function () { diff --git a/selenium/test/oauth/with-idp-initiated/unauthorized.js b/selenium/test/oauth/with-idp-initiated/unauthorized.js index c20ecb15014..5545a94ac1d 100644 --- a/selenium/test/oauth/with-idp-initiated/unauthorized.js +++ b/selenium/test/oauth/with-idp-initiated/unauthorized.js @@ -9,13 +9,18 @@ const FakePortalPage = require('../../pageobjects/FakePortalPage') describe('A user who accesses the /login URL with a token without scopes for the management UI', function () { let driver let captureScreen - + let username + let password + before(async function () { driver = buildDriver() + username = process.env.MGT_UNAUTHORIZED_CLIENT_ID_FOR_IDP_INITIATED || 'producer' + password = process.env.MGT_UNAUTHORIZED_CLIENT_SECRET_FOR_IDP_INITIATED || 'producer_secret' + captureScreen = captureScreensFor(driver, __filename) fakePortal = new FakePortalPage(driver) homePage = new SSOHomePage(driver) - await fakePortal.goToHome('producer', 'producer_secret') + await fakePortal.goToHome(username, password) if (!await fakePortal.isLoaded()) { throw new Error('Failed to load fakePortal') }