-
Notifications
You must be signed in to change notification settings - Fork 4
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
[DT-688] Disable DUOS sign-in when Sam is down #2763
Conversation
9873d6b
to
4b1b8a1
Compare
beforeEach(() => { | ||
cy.initApplicationConfig(); | ||
cy.stub(ServiceStatus, 'getConsentStatus').resolves(consentStatus); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For some reason if I add this to the tests instead, the tests fail. This is very mysterious cypress
behavior to me.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍🏽
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you have a screenshot to show what it looks like?
const init = async () => { | ||
setIsSamDown(!(await ServiceStatus.isSamHealthy())); | ||
}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why use a useEffect with no dependencies, instead of a onMount?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That is the recommended mechanism when using modern React, it's equivalent to an onMount
: https://react.dev/learn/synchronizing-with-effects#step-3-add-cleanup-if-needed
|
||
class Status extends Component { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see you've refactored this component a bit; are we moving away towards extending Conponent?/Is this a step towards typescriptifying?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes and yes, this is the old React style, we have moved to a more functional style (export const Thing = (props) => { ... return (...) };
).
See Summary section above. |
Thanks! Is it useful to say "Sam"? Will that mean anything to users? Are there mocks for this? |
I don't think we have mocks and I'm not sure about the messaging, I reused Cinye's design for the UI aspect. |
Maybe we could ask Lou, or use more broad language like "authentication" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks good, thanks!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Love the new message 👍🏽
Addresses
https://broadworkbench.atlassian.net/browse/DT-688
Summary
Takes the UI design from: https://github.com/DataBiosphere/duos-ui/tree/cc-dt-688-disable-ui-when-sam-down
Have you read Terra's Contributing Guide lately? If not, do that first.