-
Notifications
You must be signed in to change notification settings - Fork 106
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
fix: Check property existence for exclude from indexes with wildcard #1114
fix: Check property existence for exclude from indexes with wildcard #1114
Commits on May 24, 2023
-
Add a test for testing without mocks
Testing without mocks allows us to look at the code how it is functioning right now so that we can evaluate the intended behavior.
Configuration menu - View commit details
-
Copy full SHA for e02139b - Browse repository at this point
Copy the full SHA e02139bView commit details -
Objects shared by both tests should be moved into the outer block so that they can be shared.
Configuration menu - View commit details
-
Copy full SHA for f139770 - Browse repository at this point
Copy the full SHA f139770View commit details -
improve the test so that the error bubbles up
Now the test fails properly and passes properly by introducing callbacks
Configuration menu - View commit details
-
Copy full SHA for c8dd740 - Browse repository at this point
Copy the full SHA c8dd740View commit details -
isolate the latter test right now
The failure should be visible to the user and in the current state it is so now by isolating the test it becomes easier to explore solutions that work.
Configuration menu - View commit details
-
Copy full SHA for bdbe4c7 - Browse repository at this point
Copy the full SHA bdbe4c7View commit details
Commits on May 26, 2023
-
indent a describe block, modify tests to make sure they pass and refactor a function out that easily allows for testing modified parameters.
Configuration menu - View commit details
-
Copy full SHA for 24975b1 - Browse repository at this point
Copy the full SHA 24975b1View commit details -
Add two more tests for excludeFromIndexes on array
Add two more tests that address the array case for excludeIndexesFromPath. Also ensure that the conditions which check for these test cases properly ignore exclude from indexes when an array is used
Configuration menu - View commit details
-
Copy full SHA for d129b17 - Browse repository at this point
Copy the full SHA d129b17View commit details -
Move the tests over to the index file
We should not create a nomocks file because we can just group the tests under a unique describe block of test/index.ts.
Configuration menu - View commit details
-
Copy full SHA for 860afcb - Browse repository at this point
Copy the full SHA 860afcbView commit details -
Merge branch 'main' into check-property-existence-for-excludeFromInde…
…xes-with-wildcard
Configuration menu - View commit details
-
Copy full SHA for 099e8ef - Browse repository at this point
Copy the full SHA 099e8efView commit details
Commits on Sep 28, 2023
-
Merge branch 'main' into check-property-existence-for-excludeFromInde…
…xes-with-wildcard
Configuration menu - View commit details
-
Copy full SHA for 73cb4f1 - Browse repository at this point
Copy the full SHA 73cb4f1View commit details -
Merge branch 'main' of https://github.com/googleapis/nodejs-datastore …
…into check-property-existence-for-excludeFromIndexes-with-wildcard
Configuration menu - View commit details
-
Copy full SHA for 1b19906 - Browse repository at this point
Copy the full SHA 1b19906View commit details -
Configuration menu - View commit details
-
Copy full SHA for be6b20e - Browse repository at this point
Copy the full SHA be6b20eView commit details -
Merge branch 'check-property-existence-for-excludeFromIndexes-with-wi…
…ldcard' of https://github.com/danieljbruce/nodejs-datastore into check-property-existence-for-excludeFromIndexes-with-wildcard
Configuration menu - View commit details
-
Copy full SHA for 87a3f80 - Browse repository at this point
Copy the full SHA 87a3f80View commit details -
Create a function to refactor the tests
Refactor the tests so that they are more readable. There is a lot of repeated code in each test which makes comparisons hard.
Configuration menu - View commit details
-
Copy full SHA for f0900e6 - Browse repository at this point
Copy the full SHA f0900e6View commit details -
All tests for this feature now use same script
Replace all tests exercising the feature so that they all use the same test script. This will make the tests way easier to read.
Configuration menu - View commit details
-
Copy full SHA for 3e1fa90 - Browse repository at this point
Copy the full SHA 3e1fa90View commit details -
Add parameterized testing to eliminate repeated code. These tests need to be easier to read for the sake of the reviewer.
Configuration menu - View commit details
-
Copy full SHA for e43a1c3 - Browse repository at this point
Copy the full SHA e43a1c3View commit details -
Eliminate function and inline code
This function is only used once now. We should inline this code in the test.
Configuration menu - View commit details
-
Copy full SHA for b21bd99 - Browse repository at this point
Copy the full SHA b21bd99View commit details -
Add JSON stringify to test title
In the test title include the properties passed in so that it is easy to track what passed/failed.
Configuration menu - View commit details
-
Copy full SHA for 234f501 - Browse repository at this point
Copy the full SHA 234f501View commit details -
Organize code so that similar variables are used
Similar variables should be used together. Organize the code so that there is less confusion about which variables are related.
Configuration menu - View commit details
-
Copy full SHA for 17a5f2d - Browse repository at this point
Copy the full SHA 17a5f2dView commit details -
inline getExpectedConfig function
The getExpectedConfig does not need to be used anymore because its code can just be inlined in the one place it is used.
Configuration menu - View commit details
-
Copy full SHA for aedf0c9 - Browse repository at this point
Copy the full SHA aedf0c9View commit details -
Separate tests into blocks and inline code
Separate the test into blocks and inline some parameters for better test readability.
Configuration menu - View commit details
-
Copy full SHA for af1130f - Browse repository at this point
Copy the full SHA af1130fView commit details -
Add types to parameters passed into async
Stronger typing makes the code easier to read.
Configuration menu - View commit details
-
Copy full SHA for b127359 - Browse repository at this point
Copy the full SHA b127359View commit details -
Eliminate unnecessary variable assignment
Don’t assign to the Datastore variable. This is not necessary. Just use the OriginalDatastore variable directly.
Configuration menu - View commit details
-
Copy full SHA for 66d0a37 - Browse repository at this point
Copy the full SHA 66d0a37View commit details -
Ran linter and simplified source changes
The diff will be easier to read if we do not add a nested if statement and instead apply a condition on the if and change the else to else if.
Configuration menu - View commit details
-
Copy full SHA for 94d7a24 - Browse repository at this point
Copy the full SHA 94d7a24View commit details -
Configuration menu - View commit details
-
Copy full SHA for d9da7da - Browse repository at this point
Copy the full SHA d9da7daView commit details -
Configuration menu - View commit details
-
Copy full SHA for 0cd7cbc - Browse repository at this point
Copy the full SHA 0cd7cbcView commit details -
Additional adjustment to entity first path part
Apply the first suggestion in the PR to all examples
Configuration menu - View commit details
-
Copy full SHA for 377770b - Browse repository at this point
Copy the full SHA 377770bView commit details -
Define isFirstPathPartUndefined
There is a repeated code fragment for checking if the first path part is undefined that we should refactor.
Configuration menu - View commit details
-
Copy full SHA for df3f376 - Browse repository at this point
Copy the full SHA df3f376View commit details -
Configuration menu - View commit details
-
Copy full SHA for 4f54d94 - Browse repository at this point
Copy the full SHA 4f54d94View commit details -
Configuration menu - View commit details
-
Copy full SHA for a101f27 - Browse repository at this point
Copy the full SHA a101f27View commit details -
Configuration menu - View commit details
-
Copy full SHA for 2253740 - Browse repository at this point
Copy the full SHA 2253740View commit details -
Revert "Rename the variable to align with what it does"
This reverts commit 4f54d94.
Configuration menu - View commit details
-
Copy full SHA for 8db651a - Browse repository at this point
Copy the full SHA 8db651aView commit details -
Revert "Define isFirstPathPartUndefined"
This reverts commit df3f376.
Configuration menu - View commit details
-
Copy full SHA for b798ec3 - Browse repository at this point
Copy the full SHA b798ec3View commit details -
Refactor check out for seeing if defined
We do four checks to see if the first path part is defined. We should refactor these checks out.
Configuration menu - View commit details
-
Copy full SHA for 3133879 - Browse repository at this point
Copy the full SHA 3133879View commit details -
Move comment to more appropriate place
The comment should reflect the next line of code.
Configuration menu - View commit details
-
Copy full SHA for b148c95 - Browse repository at this point
Copy the full SHA b148c95View commit details
Commits on Sep 29, 2023
-
Merge branch 'main' of https://github.com/googleapis/nodejs-datastore …
…into check-property-existence-for-excludeFromIndexes-with-wildcard # Conflicts: # test/index.ts
Configuration menu - View commit details
-
Copy full SHA for e0dfef3 - Browse repository at this point
Copy the full SHA e0dfef3View commit details -
Replace comments with description
Replace comments with description property so that the tests will report the description when running the tests instead of the properties in the description.
Configuration menu - View commit details
-
Copy full SHA for d1ff7d6 - Browse repository at this point
Copy the full SHA d1ff7d6View commit details -
Configuration menu - View commit details
-
Copy full SHA for 620ee00 - Browse repository at this point
Copy the full SHA 620ee00View commit details -
Configuration menu - View commit details
-
Copy full SHA for e0d770f - Browse repository at this point
Copy the full SHA e0d770fView commit details -
Configuration menu - View commit details
-
Copy full SHA for e1aecb6 - Browse repository at this point
Copy the full SHA e1aecb6View commit details -
Merge branch 'main' into check-property-existence-for-excludeFromInde…
…xes-with-wildcard
Configuration menu - View commit details
-
Copy full SHA for d75a732 - Browse repository at this point
Copy the full SHA d75a732View commit details