-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* add sync_org to feeder options * change urls for ckan feeder * initial working version of shared idp * put back align in radio-card-group * add the shared idp aud mapper * add support for shared idp roles * upd data rule for isShared * upd controllers * fix invalid idp shared check * First pass at new login screens * fix invalid query * add namespace field to metrics * upd types * upd kong_http_requests_hourly_service grouping * upd to handle Activity feed context * Consolidate login pages to single entry * Fix dialog, button fixes. * minor cleanup * make auto the default for issuer mode * show error on failed deletion of issuer and svc acct * add validation on issuer name * add validation for availableScopes * add in the delete access catch error * Fix tabs losing data when creating/editing * Switch access request button to a button, not link * Fix button again * Add content, developer layout * Update login options order. * Fix redirect bug, multiple query params * Create shared-idp.yaml * Update init.sh * Optimized Cypress Test and added Cypress Tests for update product environment scenarios * Fix login redirect inception * upd shared-idp local * upg database * cleanup feeder init * handle logout on local properly * Add ignored redirect list, move some content to server * Fix missing type data * Update cypress scripts which were failing due to changes in fixture/test data * include identity content * upg helm chart for mongodb * upg helm chart for mongodb * upg helm chart for mongodb * upg helm chart for mongodb * upd mongodb * add auth callback page * upd mongodb deploy strategy * Update ci-build-deploy.yaml * Fix login data test ids * Added changes for login refresh scenarios * removed debugger statement * Added Testdata ID for login button * Update Test scenario for Shared IDP * Remove commented code Co-authored-by: ikethecoder <ikethecoder@copeconsulting.ca> Co-authored-by: Joshua Jones <joshua@general-metrics.com> Co-authored-by: Niraj Patel <niraj.patel@gov.bc.ca>
- Loading branch information
1 parent
ea2074d
commit a526923
Showing
11 changed files
with
190 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
{ | ||
"user": { | ||
"credentials": { | ||
"username": "local", | ||
"password": "local" | ||
} | ||
}, | ||
"namespace": "newplatform" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
class keycloakGroupPage { | ||
path: string = '/' | ||
|
||
groupTab: string = '[data-ng-controller="GroupTabCtrl"]' | ||
attributeKey: string = '[ng-model="newAttribute.key"]' | ||
attributeValue: string = '[ng-model="newAttribute.value"]' | ||
addAttributeBtn: string = '[data-ng-click="addAttribute()"]' | ||
|
||
selectTab(tabName: string){ | ||
cy.get(this.groupTab).contains('a',tabName).click() | ||
} | ||
|
||
setAttribute(attKey: string, attValue: string){ | ||
cy.wait(2000) | ||
cy.get(this.attributeKey).type(attKey) | ||
cy.get(this.attributeValue).type(attValue) | ||
cy.get(this.addAttributeBtn).click() | ||
cy.contains('button','Save').click() | ||
} | ||
} | ||
|
||
export default keycloakGroupPage |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
class KeycloakUserGroupPage { | ||
path: string = '/' | ||
|
||
editButton: string = '[id="editGroup"]' | ||
groupTab: string = '[data-ng-controller="GroupTabCtrl"]' | ||
|
||
selectTab(tabName: string){ | ||
cy.get(this.groupTab).contains('a',tabName).click() | ||
} | ||
|
||
clickOnEditButton() | ||
{ | ||
cy.get(this.editButton).click() | ||
} | ||
} | ||
|
||
export default KeycloakUserGroupPage |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
66 changes: 66 additions & 0 deletions
66
e2e/cypress/tests/08-update-product-env/05-keycloak-shared-IDP-config.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
import ApiDirectoryPage from '../../pageObjects/apiDirectory' | ||
import ApplicationPage from '../../pageObjects/applications' | ||
import AuthorizationProfile from '../../pageObjects/authProfile' | ||
import ConsumersPage from '../../pageObjects/consumers' | ||
import HomePage from '../../pageObjects/home' | ||
import keycloakGroupPage from '../../pageObjects/keycloakGroup' | ||
import KeycloakUserGroupPage from '../../pageObjects/keycloakUserGroup' | ||
import LoginPage from '../../pageObjects/login' | ||
import MyAccessPage from '../../pageObjects/myAccess' | ||
import Products from '../../pageObjects/products' | ||
|
||
describe('Apply Shared IDP config at Keycloak user group', () => { | ||
const userGroups = new KeycloakUserGroupPage() | ||
const groups = new keycloakGroupPage() | ||
var nameSpace: string | ||
const home = new HomePage() | ||
const authProfile = new AuthorizationProfile() | ||
|
||
before(() => { | ||
cy.visit(Cypress.env('KEYCLOAK_URL')) | ||
cy.deleteAllCookies() | ||
cy.reload() | ||
}) | ||
|
||
beforeEach(() => { | ||
cy.preserveCookies() | ||
cy.fixture('developer').as('developer') | ||
cy.fixture('apiowner').as('apiowner') | ||
cy.fixture('state/regen').as('regen') | ||
cy.fixture('admin').as('admin') | ||
}) | ||
|
||
it('Authenticates Admin owner', () => { | ||
cy.get('@admin').then(({ user }: any) => { | ||
cy.contains('Administration Console').click({force:true}) | ||
cy.keycloakLogin(user.credentials.username, user.credentials.password) | ||
}) | ||
}) | ||
|
||
it('Navigate to User Groups', () => { | ||
cy.contains('Groups').click() | ||
}) | ||
|
||
it('Edit the namespace from the tree view', () => { | ||
cy.get('@admin').then(({ namespace }: any) => { | ||
cy.contains(namespace).click() | ||
userGroups.clickOnEditButton() | ||
}) | ||
}) | ||
|
||
it('Navigate to attribute tab', () => { | ||
userGroups.selectTab('Attributes') | ||
}) | ||
|
||
it('Set the Attributes', () => { | ||
groups.setAttribute('perm-protected-ns','allow') | ||
}) | ||
|
||
after(() => { | ||
cy.keycloakLogout() | ||
cy.clearLocalStorage({ log: true }) | ||
cy.deleteAllCookies() | ||
}) | ||
|
||
}) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters