-
Notifications
You must be signed in to change notification settings - Fork 4
Pepper 1251 playwright place an order in mercury #2412
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
base: develop
Are you sure you want to change the base?
Pepper 1251 playwright place an order in mercury #2412
Conversation
REQUEST = 'Request', | ||
RECEIVED = 'Received', | ||
EXACT_MATCH = 'Exact Match', | ||
LOST_TO_FOLLOWUP = 'Lost to Followup', |
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.
just moved things into alphabetical order
const numberOfReturnedParticipants = await participantTable.getRowsCount(); | ||
expect(numberOfReturnedParticipants).toBeGreaterThanOrEqual(1); | ||
|
||
//Randomly chose a participant to get a clinical order who had previously had an order placed |
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.
Reason for choosing a ptp who previously had an order placed: test is a bit smaller if it does not need to send+receive a kit and accession sm-ids
currently just looks at OS2, planning on having it run in LMS too - once above initial circleci checks are done, will run tests in dev and test env to make sure no unintended errors are occurring |
running tests in dev and test to make sure it passes |
playwright-e2e/utils/date-utils.ts
Outdated
@@ -149,3 +149,7 @@ export const calculateAge = (month: string, day: string, year: string): number = | |||
|
|||
return resultAge; | |||
}; | |||
|
|||
export const getTodayInEastCoastDateTimeFormat = (): string => { |
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.
Nit: this is the time zone, not the time format.
@@ -9,6 +9,12 @@ echo "export SITE_PASSWORD=$sitePwd" >> playwright-env/envvars | |||
export bspToken=$(vault read --format=json secret/pepper/test/v1/e2e | jq -r ".data.bsp | .[] | select(.env==\"$ENV\") | .token") | |||
echo "export BSP_TOKEN=$bspToken" >> playwright-env/envvars | |||
|
|||
export pubsubTopicName=$(vault read --format=json secret/pepper/test/v1/e2e | jq -r ".data.mercury | .[] | select(.env==\"$ENV\") | .pubsubTopicName") |
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.
It looks like we aren't dipping into pubsub for these tests. Do we need these values for testing?
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.
yep - I use them in placeMercuryOrder():
I'm using the method shown here: https://cloud.google.com/pubsub/docs/publisher#node.js_1
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.
Can you say a bit more about why we need to interact with pubsub directly when there's a "place order" button on the UI?
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.
yeah - the "place order" button usually just fills the Latest Sequencing Order Date column and the Latest Order Number column. I need to use pubsub in order to make sure that the Latest Order Status and Latest PDO Number are also filled out.
Below is state of the orders with just "place order" used (see the ones with "10/15/2024" as the Latest Sequencing Order Date):
Below is after using pubsub (Latest Order Status and Latest PDO Number are now filled out):
attaching the doc that has the testing steps since video reference is too big to attach: https://docs.google.com/document/d/1TGCnJGNz-HPYo1zO7wEeVHjkhm0NEgOEQHwyoCU12aI/edit?tab=t.0
Getting the process for placing a clinical order checked out by playwright