Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(1) Not select the with_op by default as you may not have 1password CLI #276

Merged
merged 2 commits into from
May 23, 2024

Conversation

ntai-arxiv
Copy link
Contributor

(2) Make the test to run from the arxiv-base directory

(2) Make the test to run from the arxiv-base directory
gcp/service_auth/tests/test_get_token.py Outdated Show resolved Hide resolved
gcp/service_auth/tests/test_get_token.py Outdated Show resolved Hide resolved
gcp/service_auth/tests/test_get_token.py Show resolved Hide resolved
Copy link
Contributor

@bdc34 bdc34 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why are we making it so our tests require the onepassword cli tool?

@ntai-arxiv
Copy link
Contributor Author

Why are we making it so our tests require the onepassword cli tool?

If you run the pytest from arxiv-base root, it is turned off. OTOH, if you need to test the token generation, it needs a credential to run it against GCP. I stored it in 1p.

Do you have a suggestion for it? @bdc34

@bmaltzan
Copy link
Contributor

Why are we making it so our tests require the onepassword cli tool?

If you run the pytest from arxiv-base root, it is turned off. OTOH, if you need to test the token generation, it needs a credential to run it against GCP. I stored it in 1p.

Hmm, can I trust automated tests with my 1p and gcloud credentials?

@ntai-arxiv
Copy link
Contributor Author

Why are we making it so our tests require the onepassword cli tool?

If you run the pytest from arxiv-base root, it is turned off. OTOH, if you need to test the token generation, it needs a credential to run it against GCP. I stored it in 1p.

Hmm, can I trust automated tests with my 1p and gcloud credentials?

@bmaltzan The test is not meant to run in the automated test. You need to run it on your local machine with 1password CLI installed. The test has the marker "with_op" for it.

@ntai-arxiv ntai-arxiv merged commit f555170 into develop May 23, 2024
1 check passed
@ntai-arxiv ntai-arxiv deleted the ntai/fix-gcp-auth-token-tests branch July 27, 2024 12:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants