Base GPO expiration on original request date#7389
Merged
Conversation
Rather than basing on the date we FTP the .csv file out, base the expiry on the time of the original request's creation. For LG-8063 changelog: Bug Fixes, GPO, Address issue where expiration date on GPO letters was not printed correctly.
mdiarra3
pushed a commit
that referenced
this pull request
Nov 28, 2022
* Base GPO expiration on original request date Rather than basing on the date we FTP the .csv file out, base the expiry on the time of the original request's creation. For LG-8063 changelog: Bug Fixes, GPO, Address issue where expiration date on GPO letters was not printed correctly. * Switch to Time.zone.parse
matthinz
added a commit
that referenced
this pull request
Nov 28, 2022
Address a flaky test introduced in #7389. We run tests in CI with a random Timezone each time. This means sometimes the local day and UTC day are different, which was making the GPO exporter test fail. This change updates `GpoConfirmationExporter` to convert dates to UTC before outputting them. This gives us consistency on tests but should not matter in prod, where the Timezone is already set to UTC. For LG-8233 [skip changelog]
Closed
matthinz
added a commit
that referenced
this pull request
Nov 29, 2022
* Fix flaky GPO exporter test Address a flaky test introduced in #7389. We run tests in CI with a random Timezone each time. This means sometimes the local day and UTC day are different, which was making the GPO exporter test fail. This change updates `GpoConfirmationExporter` to convert dates to UTC before outputting them. This gives us consistency on tests but should not matter in prod, where the Timezone is already set to UTC. For LG-8233 [skip changelog] * Update app/services/gpo_confirmation_exporter.rb Co-authored-by: Zach Margolis <zachmargolis@users.noreply.github.com> Co-authored-by: Zach Margolis <zachmargolis@users.noreply.github.com>
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🎫 Ticket
LG-8063
🛠 Summary of changes
The expiration date printed on GPO letters was being calculated as 30 days after the GPO upload job was run rather than 30 days after the original request was made.
This PR updates the GPO exporter to base expiration dates on the
created_atfield of theGpoConfirmationrecord.