Implementing Azure devops http private repo test (#77)

* Implementing Azure devops http private repo test
* adding missing credentials.
correcting small typo
* adding az variable into docker script
* Fixing typo on test number
This commit is contained in:
Manuel Martín 2024-03-25 11:44:12 +01:00 committed by GitHub
parent ae6359321b
commit 73cac5191e
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
8 changed files with 39 additions and 1 deletions

View File

@ -38,6 +38,12 @@ on:
gh_private_pwd:
description: Github password for private repo tests
required: false
azure_private_user:
description: Azure username for private repo tests
required: false
azure_private_pwd:
description: Azure password for private repo tests
required: false
qase_api_token:
description: Qase API token to use for Qase reporting
required: true
@ -258,6 +264,8 @@ jobs:
BITBUCKET_PRIVATE_PWD: ${{ secrets.bitbucket_private_pwd }}
GH_PRIVATE_USER: ${{ secrets.gh_private_user }}
GH_PRIVATE_PWD: ${{ secrets.gh_private_pwd }}
AZURE_PRIVATE_USER: ${{ secrets.azure_private_user }}
AZURE_PRIVATE_PWD: ${{ secrets.azure_private_pwd }}
GREPTAGS: ${{ inputs.grep_test_by_tag }}
# Add /workdir/e2e/unit_tests/user.spec.ts again when implementing RBAC tests.
SPEC: |

View File

@ -24,7 +24,9 @@ jobs:
bitbucket_private_user: ${{ secrets.BITBUCKET_PRIVATE_USER }}
bitbucket_private_pwd: ${{ secrets.BITBUCKET_PRIVATE_PWD }}
gh_private_user: ${{ secrets.GH_PRIVATE_USER }}
gH_private_pwd: ${{ secrets.GH_PRIVATE_PWD }}
gh_private_pwd: ${{ secrets.GH_PRIVATE_PWD }}
azure_private_user: ${{ secrets.AZURE_PRIVATE_USER }}
azure_private_pwd: ${{ secrets.AZURE_PRIVATE_PWD }}
qase_api_token: ${{ secrets.QASE_API_TOKEN }}
with:
test_description: "CI test for PR#${{ github.event.pull_request.number }} with K3s"

View File

@ -43,6 +43,8 @@ jobs:
bitbucket_private_pwd: ${{ secrets.BITBUCKET_PRIVATE_PWD }}
gh_private_user: ${{ secrets.GH_PRIVATE_USER }}
gh_private_pwd: ${{ secrets.GH_PRIVATE_PWD }}
azure_private_user: ${{ secrets.AZURE_PRIVATE_USER }}
azure_private_pwd: ${{ secrets.AZURE_PRIVATE_PWD }}
qase_api_token: ${{ secrets.QASE_API_TOKEN }}
with:
test_description: "CI/Manual - UI - Deployment test with Standard K3s"

View File

@ -43,6 +43,8 @@ jobs:
bitbucket_private_pwd: ${{ secrets.BITBUCKET_PRIVATE_PWD }}
gh_private_user: ${{ secrets.GH_PRIVATE_USER }}
gh_private_pwd: ${{ secrets.GH_PRIVATE_PWD }}
azure_private_user: ${{ secrets.AZURE_PRIVATE_USER }}
azure_private_pwd: ${{ secrets.AZURE_PRIVATE_PWD }}
qase_api_token: ${{ secrets.QASE_API_TOKEN }}
with:
test_description: "CI/Manual - UI - Deployment test with Standard K3s"

View File

@ -43,6 +43,8 @@ jobs:
bitbucket_private_pwd: ${{ secrets.BITBUCKET_PRIVATE_PWD }}
gh_private_user: ${{ secrets.GH_PRIVATE_USER }}
gh_private_pwd: ${{ secrets.GH_PRIVATE_PWD }}
azure_private_user: ${{ secrets.AZURE_PRIVATE_USER }}
azure_private_pwd: ${{ secrets.AZURE_PRIVATE_PWD }}
qase_api_token: ${{ secrets.QASE_API_TOKEN }}
with:
test_description: "CI/Manual - UI - Deployment test with Standard K3s"

View File

@ -103,6 +103,24 @@ describe('Fleet Deployment Test Cases', { tags: '@p0' }, () => {
})
);
qase(98,
it('FLEET-98: Test AZURE DEVOPS Private Repository to install NGINX app using HTTP auth', { tags: '@fleet-98' }, () => {
const repoName = "default-cluster-fleet-52"
const branch = "main"
const path = "nginx-helm"
const repoUrl = "https://dev.azure.com/mamartin0216/_git/mamartin"
const gitAuthType = "http"
const userOrPublicKey = Cypress.env("azure_private_user");
const pwdOrPrivateKey = Cypress.env("azure_private_pwd");
cy.fleetNamespaceToggle('fleet-default')
cy.addFleetGitRepo({ repoName, repoUrl, branch, path, gitAuthType, userOrPublicKey, pwdOrPrivateKey });
cy.clickButton('Create');
cy.open3dotsMenu(repoName, 'Force Update');
cy.checkGitRepoStatus(repoName, '1 / 1', '1 / 1')
cy.deleteAllFleetRepos();
})
);
});

View File

@ -41,6 +41,8 @@ module.exports = (on: Cypress.PluginEvents, config: Cypress.PluginConfigOptions)
config.env.bitbucket_private_pwd = process.env.BITBUCKET_PRIVATE_PWD;
config.env.gh_private_user = process.env.GH_PRIVATE_USER;
config.env.gh_private_pwd = process.env.GH_PRIVATE_PWD;
config.env.azure_private_user = process.env.AZURE_PRIVATE_USER;
config.env.azure_private_pwd = process.env.AZURE_PRIVATE_PWD;
config.env.grep = process.env.GREP;
config.env.grepTags = process.env.GREPTAGS;

View File

@ -23,6 +23,8 @@ docker run --init -v $PWD:/workdir -w /workdir \
-e BITBUCKET_PRIVATE_PWD=$BITBUCKET_PRIVATE_PWD \
-e GH_PRIVATE_USER=$GH_PRIVATE_USER \
-e GH_PRIVATE_PWD=$GH_PRIVATE_PWD \
-e AZURE_PRIVATE_USER=$AZURE_PRIVATE_USER \
-e AZURE_PRIVATE_PWD=$AZURE_PRIVATE_PWD \
-e "GREP=$GREP" \
-e "GREPTAGS=$GREPTAGS" \
--add-host host.docker.internal:host-gateway \