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

test(secrets): cypress tests for secrets #161

Merged
merged 9 commits into from
May 13, 2020
Merged

test(secrets): cypress tests for secrets #161

merged 9 commits into from
May 13, 2020

Conversation

plyr4
Copy link
Contributor

@plyr4 plyr4 commented May 12, 2020

No description provided.

@plyr4 plyr4 requested a review from a team as a code owner May 12, 2020 14:30
"There was an error fetching your available repositories... Click Refresh or try again later!"
]
]
viewResourceError { resourceLabel = "your available repositories", testLabel = "repos" }
Copy link
Contributor Author

Choose a reason for hiding this comment

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

added a helper class for the "try again later!" we test for

in
( { model | secretsModel = { secretsModel | secrets = mergedSecrets } }, Cmd.none )

Err error ->
Copy link
Contributor Author

Choose a reason for hiding this comment

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

added account for GET failure

@@ -89,3 +91,17 @@ wrapErrorContent content =

else
" (" ++ content ++ ")"


{-| viewResourceError : renders generic error message when there is a problem fetching a resource from Vela.
Copy link
Contributor Author

Choose a reason for hiding this comment

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

helper function for rendering GET failures

@@ -1067,6 +1069,45 @@ secretTypeToString type_ =
"repo"


{-| secretsErrorLabel : helper to convert SecretType to string for printing GET secrets resource errors
Copy link
Contributor Author

Choose a reason for hiding this comment

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

added some more info for GET failures on particular secrets data

Copy link
Contributor

@jbrockopp jbrockopp left a comment

Choose a reason for hiding this comment

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

LGTM

@jbrockopp jbrockopp merged commit 73ac3ff into master May 13, 2020
@jbrockopp jbrockopp deleted the test_secrets branch May 13, 2020 16:36
plyr4 added a commit that referenced this pull request Aug 19, 2022
* wrapped secret in RemoteData, added resourceError helper class, added remotedata failure logic to secrets page

* lint

* adding test labels to Table.View

* more generic cypress tests for rendering secrets

* cypress tests. linting.

* oof, forgot to update hooks

* remove redundant case

* updating grammar in add repos test
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.

3 participants