RedHatInsights / insights-chrome

Chroming for Insights apps
MIT License
27 stars 130 forks source link

Add package that displays a message for oudated browser #2872

Open randomnetcat opened 2 months ago

randomnetcat commented 2 months ago

See RHCLOUD-27572.

The outdatedBrowser() call does accept an argument that tells it what browser versions to consider outdated, but I wasn't sure how to even start approaching determining that. For instance, the Patternfly documentation says the supported version for all browser is "latest", which is... less than helpful.

codecov-commenter commented 2 months ago

Codecov Report

Attention: Patch coverage is 0% with 1 line in your changes missing coverage. Please review.

Project coverage is 63.66%. Comparing base (4349edb) to head (b1b7f2d).

:exclamation: Current head b1b7f2d differs from pull request most recent head a40fa24

Please upload reports for the commit a40fa24 to get more accurate results.

Additional details and impacted files [![Impacted file tree graph](https://app.codecov.io/gh/RedHatInsights/insights-chrome/pull/2872/graphs/tree.svg?width=650&height=150&src=pr&token=GuRwyW1uUf&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=RedHatInsights)](https://app.codecov.io/gh/RedHatInsights/insights-chrome/pull/2872?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=RedHatInsights) ```diff @@ Coverage Diff @@ ## master #2872 +/- ## ========================================== + Coverage 63.59% 63.66% +0.07% ========================================== Files 202 203 +1 Lines 4650 4651 +1 Branches 858 858 ========================================== + Hits 2957 2961 +4 + Misses 1683 1680 -3 Partials 10 10 ``` | [Files](https://app.codecov.io/gh/RedHatInsights/insights-chrome/pull/2872?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=RedHatInsights) | Coverage Δ | | |---|---|---| | [src/components/Footer/Footer.tsx](https://app.codecov.io/gh/RedHatInsights/insights-chrome/pull/2872?src=pr&el=tree&filepath=src%2Fcomponents%2FFooter%2FFooter.tsx&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=RedHatInsights#diff-c3JjL2NvbXBvbmVudHMvRm9vdGVyL0Zvb3Rlci50c3g=) | `75.00% <ø> (ø)` | | | [src/outdated-browser.js](https://app.codecov.io/gh/RedHatInsights/insights-chrome/pull/2872?src=pr&el=tree&filepath=src%2Foutdated-browser.js&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=RedHatInsights#diff-c3JjL291dGRhdGVkLWJyb3dzZXIuanM=) | `0.00% <0.00%> (ø)` | | ... and [1 file with indirect coverage changes](https://app.codecov.io/gh/RedHatInsights/insights-chrome/pull/2872/indirect-changes?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=RedHatInsights)
Hyperkid123 commented 2 months ago

/retest

Hyperkid123 commented 2 months ago

/retest

Hyperkid123 commented 2 months ago

Seems like the extensions is messing with e2e cypress/iqe tests:

image

randomnetcat commented 2 months ago

It appears Cypress is configured to use an ancient User-Agent https://github.com/RedHatInsights/insights-chrome/blob/d17fb3de33d95128a92c8b2fd0f20fa743d50375/cypress.config.ts#L46-L47 . Can that be changed at this point? Not sure what the "chromium issue" is.

ryelo commented 2 months ago

We should run the content and banner by UX do double check brand standards. I know from looking the banner doesn't follow PatternFly guidelines and would like to see if they have guidance for us.

Hyperkid123 commented 2 months ago

@randomnetcat

Can that be changed at this point? Not sure what the "chromium issue" is.

It might be. It's very likely the lib is looking at this. its worth a shot. If that says its chrome 51 its basically an ancient version. Current is 120 or something.

randomnetcat commented 2 months ago

Updated the userAgent. I still have a test failing locally, but it appeared to also be failing on master?

Hyperkid123 commented 2 months ago

/retest

There is always one run failing