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

(#12) Page Not Found for Disease #40

Merged
merged 1 commit into from
Apr 1, 2021
Merged

Conversation

kate-mashkina
Copy link
Contributor

  • enabled PageNotFound for 404 status
  • added prerender meta tag
  • added integration tests

Closes #12

@kate-mashkina
Copy link
Contributor Author

@mworrest as we discussed, search bar and submit button are now full width at <641 px - please re-check the PR https://react-app-dev.cancer.gov/clinical-trials-listing-app/pr-40/c456667?cfg=0

@mworrest
Copy link

Looks good--thanks!

@alinai
Copy link

alinai commented Mar 23, 2021

Looks good. Thanks @kate-mashkina!

Copy link
Member

@bryanpizzillo bryanpizzillo left a comment

Choose a reason for hiding this comment

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

Please fix the proxy to support known 404 urls that should respond with a 404, and not litter the test output with file not found errors.

The example from the output:

[Error: ENOENT: no such file or directory, open '/home/runner/work/clinical-trials-listing-app/clinical-trials-listing-app/support/mock-data/listing-information/c123455.json'] {
  errno: -2,
  code: 'ENOENT',
  syscall: 'open',
  path: '/home/runner/work/clinical-trials-listing-app/clinical-trials-listing-app/support/mock-data/listing-information/c123455.json'
}
No listing-information mock found for request.
    ✓ Page Load Analytics fires for a 404 on a disease dynamic listing page with non-existent c-code (2292ms)
[Error: ENOENT: no such file or directory, open '/home/runner/work/clinical-trials-listing-app/clinical-trials-listing-app/support/mock-data/listing-information/chicken-nugget.json'] {
  errno: -2,
  code: 'ENOENT',
  syscall: 'open',
  path: '/home/runner/work/clinical-trials-listing-app/clinical-trials-listing-app/support/mock-data/listing-information/chicken-nugget.json'
}

Additionally I see another error in the logs:
(node:3270) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 preprocessor:close listeners added to [EventEmitter]. Use emitter.setMaxListeners() to increase limit

@kate-mashkina
Copy link
Contributor Author

@bryanpizzillo I took care of the proxy.
The other error mentioned appears to be an obvious Cypress's issue and still outstanding (see here cypress-io/cypress#1305) - but the good thing is that Cypress assures it does not cause things to crash.
I've done more digging and the same issue was also present in drug dictionary tests( precisely at the 10th feature it would be logged... so it just happens that pageNotFound is the 10th)

@@ -0,0 +1 @@
{"Message":"Could not find codes 'c12345'."}
Copy link
Contributor

Choose a reason for hiding this comment

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

blecch. So this came up in the app scan as having needed to be changed. @sarinapadilla those changes haven't been made yet, right?

- enabled PageNotFound for 404 status
- added prerender meta tag
- added integration tests
- made search box and button size relative
to the screen size on mobile
- added additional 404 proxy check
- added mock files
@arcepaul arcepaul merged commit 9cdba06 into develop Apr 1, 2021
@arcepaul arcepaul deleted the ticket/12-page-not-found branch April 1, 2021 20:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Story: "404" Screen for when the disease does not exist.
7 participants