-
Notifications
You must be signed in to change notification settings - Fork 3
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
TD-3368 - Enhanced Vehicle Selector #1039
base: release/v11.2.0
Are you sure you want to change the base?
TD-3368 - Enhanced Vehicle Selector #1039
Conversation
- auto selection extending in component - isolated repeat code abstraction and tests - Updated tests to test auto selection
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.
Functionality works fine. See suggestions to seperate types
@stevenmcsorleyipg why it this PR pointing to main? Did you test this in VIRTO? |
there will be a pre-release for this PR |
Ok but this should be targetting to a release branch not main |
- moved props to types - fixed function calls - fixed tests
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 think we normally dont follow two .test.tsx
files for a single component. I understand why you created it but i'm not sure whether this is a good practice or not, @mattcorner what you think about having VehicleSelector.test.tsx
for main component and VehicleSelector.autoSelect.test.tsx
for some functionality?
Its fine I can move all the tests into one file |
- moved all tests into one file - applied suggestion to types to lessen duplication
Yes please stick with one test file per component. If you want to group different tests by the behaviour that they are testing then you can use |
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.
LGTM, Please gets it approved by @Sowbhagya-ipg as well.
@stevenmcsorleyipg I will do the final approval once @Sowbhagya-ipg is happy and you have done testing in VIRTO with a pre-release. |
Looks good. No issues @stevenmcsorleyipg |
* Changed the TransferList to have combined search and check functionality and added one more test * 11.1.0-0 * Addressed the PR feedback, added a few tests * Added another test to check simultaneously checked --------- Co-authored-by: IvanLazarov-TVM <i.lazarov@tvm-engineering.com> Co-authored-by: lukemojo <143453762+lukemojo@users.noreply.github.com>
Closes/Contributes TD-3368
Changes
Added auto selection by extending the current functionality without breaking or modifying the current code, all tests and
storybook passed and worked after the auto selection logic was added, more data has been added to the storybook file to
demonstrate the levels of auto selection versus manual selection where it arises.
Over abstraction is easy, so in this we have abstracted logic that makes sense to abstract with purpose and is repeated and
makes sense to turn into easy to read
functions with intention names ie: shouldAutoSelect, createVehicleRecord and filterVehicles
These are specific to VehicleSelector so are not globally used functions, they just make the VehicleSelector component easier
to read, easier to test and help document the logic in the component.
Dependencies
N/A
UI/UX
tagging Ux @Sowbhagya-ipg
td-3368.mp4
Testing notes
Test in story book
Author checklist
Before I request a review:
- [ ] I have tested the changes in Docker / a deploy-preview.- [ ] I have populated the deploy-preview with relevant test data.