All new code requires tests to ensure against regressions.
However, if your PR contains zero code changes, feel free to select the checkmark below to indicate so.
[X] Have you ran tests against this code?
[ ] This PR contains zero code changes.
Description of the Change
This PR implements using joi for describing and checking an objects adherence to a schema.
This could potentially allow us to easily define the proper schema for everything, like a Package Object Full and Package Object Short and quickly determine if our code is returning the exact objects that we expect.
We can see here in the two unit tests I've added it to, they have already been greatly simplified by it's usage, and ideally we will be able to see this behavior further across the codebase.
Requirements
Filling out the template is required.
All new code requires tests to ensure against regressions.
[X] Have you ran tests against this code?
[ ] This PR contains zero code changes.
Description of the Change
This PR implements using
joi
for describing and checking an objects adherence to a schema.This could potentially allow us to easily define the proper schema for everything, like a
Package Object Full
andPackage Object Short
and quickly determine if our code is returning the exact objects that we expect.We can see here in the two unit tests I've added it to, they have already been greatly simplified by it's usage, and ideally we will be able to see this behavior further across the codebase.