This repository has been archived by the owner on Jan 9, 2023. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #14 from kcdraidgroup/juhanakristian
Converts Imagings.test.tsx to RTL
- Loading branch information
Showing
2 changed files
with
317 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
311 changes: 311 additions & 0 deletions
311
src/__tests__/imagings/__snapshots__/Imagings.test.tsx.snap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,311 @@ | ||
// Jest Snapshot v1, https://goo.gl/fbAQLP | ||
|
||
|
||
exports[`Imagings routing /imaging/new should render the new imaging request screen when /imaging/new is accessed 1`] = ` | ||
<div> | ||
<form> | ||
<div | ||
class="row" | ||
> | ||
<div | ||
class="col" | ||
> | ||
<div | ||
class="form-group patient-typeahead" | ||
> | ||
<div> | ||
<label | ||
class="form-label" | ||
for="patientTypeahead" | ||
title="This is a required input" | ||
> | ||
imagings.imaging.patient | ||
<i | ||
style="color: red;" | ||
> | ||
<svg | ||
aria-hidden="true" | ||
class="svg-inline--fa fa-asterisk fa-w-16 " | ||
data-icon="asterisk" | ||
data-prefix="fas" | ||
focusable="false" | ||
role="img" | ||
style="height: 7px; vertical-align: top; margin-left: 2px;" | ||
viewBox="0 0 512 512" | ||
xmlns="http://www.w3.org/2000/svg" | ||
> | ||
<path | ||
d="M478.21 334.093L336 256l142.21-78.093c11.795-6.477 15.961-21.384 9.232-33.037l-19.48-33.741c-6.728-11.653-21.72-15.499-33.227-8.523L296 186.718l3.475-162.204C299.763 11.061 288.937 0 275.48 0h-38.96c-13.456 0-24.283 11.061-23.994 24.514L216 186.718 77.265 102.607c-11.506-6.976-26.499-3.13-33.227 8.523l-19.48 33.741c-6.728 11.653-2.562 26.56 9.233 33.037L176 256 33.79 334.093c-11.795 6.477-15.961 21.384-9.232 33.037l19.48 33.741c6.728 11.653 21.721 15.499 33.227 8.523L216 325.282l-3.475 162.204C212.237 500.939 223.064 512 236.52 512h38.961c13.456 0 24.283-11.061 23.995-24.514L296 325.282l138.735 84.111c11.506 6.976 26.499 3.13 33.227-8.523l19.48-33.741c6.728-11.653 2.563-26.559-9.232-33.036z" | ||
fill="currentColor" | ||
/> | ||
</svg> | ||
</i> | ||
</label> | ||
</div> | ||
<div | ||
class="rbt" | ||
style="outline: none; position: relative;" | ||
tabindex="-1" | ||
> | ||
<div | ||
style="display: flex; flex: 1; height: 100%; position: relative;" | ||
> | ||
<input | ||
aria-autocomplete="both" | ||
aria-expanded="false" | ||
aria-haspopup="listbox" | ||
autocomplete="off" | ||
class="rbt-input-main form-control rbt-input" | ||
placeholder="imagings.imaging.patient" | ||
role="combobox" | ||
type="text" | ||
value="" | ||
/> | ||
<input | ||
aria-hidden="true" | ||
class="rbt-input-hint" | ||
readonly="" | ||
style="background-color: transparent; border-color: transparent; box-shadow: none; color: rgba(0, 0, 0, 0.35); left: 0px; pointer-events: none; position: absolute; top: 0px; width: 100%;" | ||
tabindex="-1" | ||
value="" | ||
/> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
<div | ||
class="col" | ||
> | ||
<div | ||
class="visits" | ||
> | ||
<div | ||
class="form-group" | ||
> | ||
<div> | ||
<label | ||
class="form-label" | ||
for="visitSelect" | ||
title="This is a required input" | ||
> | ||
patient.visits.label | ||
<i | ||
style="color: red;" | ||
> | ||
<svg | ||
aria-hidden="true" | ||
class="svg-inline--fa fa-asterisk fa-w-16 " | ||
data-icon="asterisk" | ||
data-prefix="fas" | ||
focusable="false" | ||
role="img" | ||
style="height: 7px; vertical-align: top; margin-left: 2px;" | ||
viewBox="0 0 512 512" | ||
xmlns="http://www.w3.org/2000/svg" | ||
> | ||
<path | ||
d="M478.21 334.093L336 256l142.21-78.093c11.795-6.477 15.961-21.384 9.232-33.037l-19.48-33.741c-6.728-11.653-21.72-15.499-33.227-8.523L296 186.718l3.475-162.204C299.763 11.061 288.937 0 275.48 0h-38.96c-13.456 0-24.283 11.061-23.994 24.514L216 186.718 77.265 102.607c-11.506-6.976-26.499-3.13-33.227 8.523l-19.48 33.741c-6.728 11.653-2.562 26.56 9.233 33.037L176 256 33.79 334.093c-11.795 6.477-15.961 21.384-9.232 33.037l19.48 33.741c6.728 11.653 21.721 15.499 33.227 8.523L216 325.282l-3.475 162.204C212.237 500.939 223.064 512 236.52 512h38.961c13.456 0 24.283-11.061 23.995-24.514L296 325.282l138.735 84.111c11.506 6.976 26.499 3.13 33.227-8.523l19.48-33.741c6.728-11.653 2.563-26.559-9.232-33.036z" | ||
fill="currentColor" | ||
/> | ||
</svg> | ||
</i> | ||
</label> | ||
</div> | ||
<div | ||
class="rbt" | ||
style="outline: none; position: relative;" | ||
tabindex="-1" | ||
> | ||
<div | ||
style="display: flex; flex: 1; height: 100%; position: relative;" | ||
> | ||
<input | ||
aria-autocomplete="both" | ||
aria-expanded="false" | ||
aria-haspopup="listbox" | ||
autocomplete="off" | ||
class="rbt-input-main form-control rbt-input" | ||
placeholder="-- Choose --" | ||
role="combobox" | ||
type="text" | ||
value="" | ||
/> | ||
<input | ||
aria-hidden="true" | ||
class="rbt-input-hint" | ||
readonly="" | ||
style="background-color: transparent; border-color: transparent; box-shadow: none; color: rgba(0, 0, 0, 0.35); left: 0px; pointer-events: none; position: absolute; top: 0px; width: 100%;" | ||
tabindex="-1" | ||
value="" | ||
/> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
<div | ||
class="form-group" | ||
> | ||
<div> | ||
<label | ||
class="form-label" | ||
for="imagingTypeTextInput" | ||
title="This is a required input" | ||
> | ||
imagings.imaging.type | ||
<i | ||
style="color: red;" | ||
> | ||
<svg | ||
aria-hidden="true" | ||
class="svg-inline--fa fa-asterisk fa-w-16 " | ||
data-icon="asterisk" | ||
data-prefix="fas" | ||
focusable="false" | ||
role="img" | ||
style="height: 7px; vertical-align: top; margin-left: 2px;" | ||
viewBox="0 0 512 512" | ||
xmlns="http://www.w3.org/2000/svg" | ||
> | ||
<path | ||
d="M478.21 334.093L336 256l142.21-78.093c11.795-6.477 15.961-21.384 9.232-33.037l-19.48-33.741c-6.728-11.653-21.72-15.499-33.227-8.523L296 186.718l3.475-162.204C299.763 11.061 288.937 0 275.48 0h-38.96c-13.456 0-24.283 11.061-23.994 24.514L216 186.718 77.265 102.607c-11.506-6.976-26.499-3.13-33.227 8.523l-19.48 33.741c-6.728 11.653-2.562 26.56 9.233 33.037L176 256 33.79 334.093c-11.795 6.477-15.961 21.384-9.232 33.037l19.48 33.741c6.728 11.653 21.721 15.499 33.227 8.523L216 325.282l-3.475 162.204C212.237 500.939 223.064 512 236.52 512h38.961c13.456 0 24.283-11.061 23.995-24.514L296 325.282l138.735 84.111c11.506 6.976 26.499 3.13 33.227-8.523l19.48-33.741c6.728-11.653 2.563-26.559-9.232-33.036z" | ||
fill="currentColor" | ||
/> | ||
</svg> | ||
</i> | ||
</label> | ||
</div> | ||
<div | ||
class="form-group" | ||
> | ||
<input | ||
class="form-control" | ||
id="imagingTypeTextInput" | ||
placeholder="imagings.imaging.type" | ||
type="text" | ||
value="" | ||
/> | ||
<div | ||
class="text-left ml-3 mt-1 text-small undefined invalid-feedback" | ||
/> | ||
</div> | ||
</div> | ||
<div | ||
class="imaging-status" | ||
> | ||
<div | ||
class="form-group" | ||
> | ||
<div> | ||
<label | ||
class="form-label" | ||
for="statusSelect" | ||
title="This is a required input" | ||
> | ||
imagings.imaging.status | ||
<i | ||
style="color: red;" | ||
> | ||
<svg | ||
aria-hidden="true" | ||
class="svg-inline--fa fa-asterisk fa-w-16 " | ||
data-icon="asterisk" | ||
data-prefix="fas" | ||
focusable="false" | ||
role="img" | ||
style="height: 7px; vertical-align: top; margin-left: 2px;" | ||
viewBox="0 0 512 512" | ||
xmlns="http://www.w3.org/2000/svg" | ||
> | ||
<path | ||
d="M478.21 334.093L336 256l142.21-78.093c11.795-6.477 15.961-21.384 9.232-33.037l-19.48-33.741c-6.728-11.653-21.72-15.499-33.227-8.523L296 186.718l3.475-162.204C299.763 11.061 288.937 0 275.48 0h-38.96c-13.456 0-24.283 11.061-23.994 24.514L216 186.718 77.265 102.607c-11.506-6.976-26.499-3.13-33.227 8.523l-19.48 33.741c-6.728 11.653-2.562 26.56 9.233 33.037L176 256 33.79 334.093c-11.795 6.477-15.961 21.384-9.232 33.037l19.48 33.741c6.728 11.653 21.721 15.499 33.227 8.523L216 325.282l-3.475 162.204C212.237 500.939 223.064 512 236.52 512h38.961c13.456 0 24.283-11.061 23.995-24.514L296 325.282l138.735 84.111c11.506 6.976 26.499 3.13 33.227-8.523l19.48-33.741c6.728-11.653 2.563-26.559-9.232-33.036z" | ||
fill="currentColor" | ||
/> | ||
</svg> | ||
</i> | ||
</label> | ||
</div> | ||
<div | ||
class="rbt" | ||
style="outline: none; position: relative;" | ||
tabindex="-1" | ||
> | ||
<div | ||
style="display: flex; flex: 1; height: 100%; position: relative;" | ||
> | ||
<input | ||
aria-autocomplete="both" | ||
aria-expanded="false" | ||
aria-haspopup="listbox" | ||
autocomplete="off" | ||
class="rbt-input-main form-control rbt-input" | ||
placeholder="-- Choose --" | ||
role="combobox" | ||
type="text" | ||
value="imagings.status.requested" | ||
/> | ||
<input | ||
aria-hidden="true" | ||
class="rbt-input-hint" | ||
readonly="" | ||
style="background-color: transparent; border-color: transparent; box-shadow: none; color: rgba(0, 0, 0, 0.35); left: 0px; pointer-events: none; position: absolute; top: 0px; width: 100%;" | ||
tabindex="-1" | ||
value="" | ||
/> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
<div | ||
class="form-group" | ||
> | ||
<div | ||
class="form-group" | ||
> | ||
<label | ||
class="form-label" | ||
for="ImagingNotesTextField" | ||
> | ||
imagings.imaging.notes | ||
</label> | ||
<div | ||
class="form-group" | ||
> | ||
<textarea | ||
class="form-control" | ||
rows="4" | ||
/> | ||
<div | ||
class="invalid-feedback" | ||
/> | ||
</div> | ||
</div> | ||
</div> | ||
<div | ||
class="row float-right" | ||
> | ||
<div | ||
class="btn-group btn-group-lg mt-3" | ||
> | ||
<button | ||
class="mr-2 btn btn-success" | ||
type="button" | ||
> | ||
actions.save | ||
</button> | ||
<button | ||
class="btn btn-danger" | ||
type="button" | ||
> | ||
actions.cancel | ||
</button> | ||
</div> | ||
</div> | ||
</form> | ||
</div> | ||
`; |