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

fix(snapshot): add test pipelinerun list and capitalize breadcrumbs #847

Merged
merged 3 commits into from
Nov 28, 2023

Conversation

abhinandan13jan
Copy link
Contributor

@abhinandan13jan abhinandan13jan commented Oct 30, 2023

Fixes

https://issues.redhat.com/browse/RHTAPBUGS-839

Description

  • Updates PLR list to include test PLRs with snapshot label
  • capitalizes snapshot in breadcrumb
  • capitalizes Environmenr names

Type of change

  • Feature
  • Bugfix
  • Code style update (formatting, renaming)
  • Refactoring (no functional changes, no api changes)
  • Build related changes
  • Documentation content changes
  • Other (please describe):

Screen shots / Gifs for design review

Screenshot 2023-10-31 at 6 26 16 PM Screenshot 2023-10-31 at 6 26 25 PM Screenshot 2023-10-30 at 8 16 24 PM Screenshot 2023-10-30 at 8 16 39 PM

How to test or reproduce?

Browser conformance:

  • Chrome
  • Firefox
  • Safari
  • Edge

@openshift-ci openshift-ci bot requested review from Katka92 and rottencandy October 30, 2023 14:59
@codecov
Copy link

codecov bot commented Oct 30, 2023

Codecov Report

Merging #847 (c814c03) into main (950ea9e) will increase coverage by 0.07%.
The diff coverage is 81.81%.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #847      +/-   ##
==========================================
+ Coverage   85.59%   85.67%   +0.07%     
==========================================
  Files         596      596              
  Lines       15041    15046       +5     
  Branches     4214     4217       +3     
==========================================
+ Hits        12875    12890      +15     
+ Misses       2029     2020       -9     
+ Partials      137      136       -1     
Files Coverage Δ
...SnapshotDetails/EnvironmentProvisionErrorAlert.tsx 100.00% <100.00%> (ø)
...mponents/SnapshotDetails/tabs/SnapshotOverview.tsx 100.00% <100.00%> (+6.06%) ⬆️
.../SnapshotDetails/tabs/SnapshotPipelineRunsList.tsx 86.51% <ø> (ø)
...s/SnapshotDetails/tabs/SnapshotPipelineRunsTab.tsx 90.62% <100.00%> (+6.75%) ⬆️
...components/SnapshotDetails/SnapshotDetailsView.tsx 91.04% <60.00%> (+7.96%) ⬆️

... and 1 file with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 950ea9e...c814c03. Read the comment docs.

@mattreid
Copy link

Is Type being lowercase in the filter selector coming from data, or our code? Other areas we're filtering on PLR type, it shows as capitalized (Build, Test).

@abhinandan13jan
Copy link
Contributor Author

/retest

@abhinandan13jan
Copy link
Contributor Author

@mattreid we get it as lowercase types from the object metadata. I updated to capitalize it while displaying
Screenshot 2023-10-31 at 6 26 25 PM

@@ -147,7 +147,7 @@ const SnapshotDetailsView: React.FC<SnapshotDetailsViewProps> = ({
<>
<StatusIconWithTextLabel
key={env.metadata?.name}
text={env.metadata.name}
text={capitalize(env.metadata.name)}
Copy link
Contributor

Choose a reason for hiding this comment

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

There is a env.spec?.displayName optional field in Environment CR, We must use that if exists or else fallback to the env.metadata.name. This way we will be be respecting the user's choice of displayName rather than Capitalizing the K8s resource name.

Copy link
Contributor

Choose a reason for hiding this comment

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

Deployment tab uses the above approach, so the Development text comes from spec.displayName and notice the other environment which doesn't have displayName and it uses resource name. Can we stick to this displayName or resource.name (without captializing) approach for consistency ? cc: @mattreid

image

@openshift-merge-robot openshift-merge-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Nov 3, 2023
@openshift-merge-robot openshift-merge-robot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Nov 3, 2023
@@ -108,7 +109,7 @@ const SnapshotOverviewTab: React.FC<SnapshotOverviewTabProps> = ({
<Link
to={`/application-pipeline/workspaces/${workspace}/applications/${snapshot.spec.application}/deployments`}
>
{env}
{capitalize(env)}
Copy link
Contributor

@rottencandy rottencandy Nov 21, 2023

Choose a reason for hiding this comment

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

I think we should use environment's spec.displayName here as well. WDYT?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

updated

Copy link
Contributor

@rottencandy rottencandy left a comment

Choose a reason for hiding this comment

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

Looking good, but looks like we need more tests to satisfy codecov

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Nov 22, 2023
Copy link
Contributor

openshift-ci bot commented Nov 22, 2023

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: abhinandan13jan, rottencandy
Once this PR has been reviewed and has the lgtm label, please assign jrichter1 for approval. For more information see the Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci openshift-ci bot removed the lgtm Indicates that a PR is ready to be merged. label Nov 22, 2023
Copy link
Contributor

openshift-ci bot commented Nov 22, 2023

New changes are detected. LGTM label has been removed.

@abhinandan13jan abhinandan13jan force-pushed the fix-snapshot-plr-list branch 5 times, most recently from 13c47d0 to 5939ce9 Compare November 23, 2023 14:13
@rottencandy
Copy link
Contributor

/retest

@abhinandan13jan
Copy link
Contributor Author

/retest

Copy link
Contributor

openshift-ci bot commented Nov 28, 2023

@abhinandan13jan: all tests passed!

Full PR test history. Your PR dashboard.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@rohitkrai03 rohitkrai03 merged commit b7359d4 into openshift:main Nov 28, 2023
5 of 7 checks passed
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.

6 participants