-
Notifications
You must be signed in to change notification settings - Fork 9
temp: test #107
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: main
Are you sure you want to change the base?
temp: test #107
Conversation
| const metaString = Object.entries(meta) | ||
| .map(([key, value]) => (key === '$tempId' ? `'$tempId': '_:${value}'` : `'${key}': '${value}'`)) | ||
| .join(','); | ||
| const OUTPUT = `(CREATE ONLY Delta SET input = ${restString}, meta = {${metaString}, "$sid": $parent.id, "$id": record::id($parent.id)}, after = $after, before = $before RETURN VALUE $parent.id )`; |
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.
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.
Caution
Changes requested ❌
Reviewed everything up to fd0e38b in 3 minutes and 34 seconds. Click for details.
- Reviewed
208lines of code in3files - Skipped
0files when reviewing. - Skipped posting
7draft comments. View those below. - Modify your settings and rules to customize what types of comments Ellipsis leaves. And don't forget to react with 👍 or 👎 to teach Ellipsis.
1. tests/test.sh:18
- Draft comment:
Typo in comment: 'argumentsppa' should be 'arguments'. - Reason this comment was not posted:
Comment was not on a location in the diff, so it can't be submitted as a review comment.
2. tests/unit/mutations/basic.ts:1008
- Draft comment:
Error message mismatch: this check verifies 'secondUser.id', so the thrown error message should reference 'secondUser.id' not 'firstUser.id'. - Reason this comment was not posted:
Comment was not on a location in the diff, so it can't be submitted as a review comment.
3. tests/unit/mutations/basic.ts:2507
- Draft comment:
Entity type mismatch in cleanup for enum1 test: A Company is created but deletion is performed with $entity: 'Hook'. Update to use 'Company'. - Reason this comment was not posted:
Comment was not on a location in the diff, so it can't be submitted as a review comment.
4. tests/unit/mutations/basic.ts:2580
- Draft comment:
Remove debug logging: Consider removing the console.log ('RES!', mutationResult) unless needed for diagnosing failures. - Reason this comment was not posted:
Decided after close inspection that this draft comment was likely wrong and/or not actionable: usefulness confidence = 20% vs. threshold = 50% While removing debug logging is generally good practice, this is in a test file and the test is marked as skipped (it.skip). The console.log may be intentionally left in to help debug the test when it's unskipped. Test files often keep debug logging commented out or wrapped in conditionals for future debugging. The comment is technically correct that debug logging should be removed, but it may be too aggressive in a test context where debug logging can be valuable. The test being skipped suggests it's still under development. Given that this is a skipped test that appears to be under development, the console.log may be intentionally left in for debugging purposes when the test is ready to be enabled. The comment should be deleted since this is a skipped test under development where debug logging may be intentionally left in for future use.
5. tests/unit/mutations/basic.ts:2433
- Draft comment:
Remove debug logging from error catch: The console.log('log', err) inside the pf4 test may be removed or replaced with proper test error assertions. - Reason this comment was not posted:
Comment was not on a location in the diff, so it can't be submitted as a review comment.
6. src/stateMachine/mutation/surql/build.ts:10
- Draft comment:
Consider refactoring inner functions: Functions like buildThings, buildEdges, buildArcs, and buildReferences are defined inside buildSURQLMutation. Moving them outside (and passing necessary parameters) may improve clarity and testability. - Reason this comment was not posted:
Confidence changes required:33%<= threshold50%None
7. tests/unit/mutations/basic.ts:1160
- Draft comment:
Consider refactoring repetitive cleanup logic: Several tests perform similar cleanup mutations. Extracting common cleanup routines could reduce code duplication. - Reason this comment was not posted:
Confidence changes required:33%<= threshold50%None
Workflow ID: wflow_LwC4tTgXaRNJYpnD
You can customize by changing your verbosity settings, reacting with 👍 or 👎, replying to comments, or adding code review rules.
| ], | ||
| }); | ||
|
|
||
| console.log('BFI2 MUTATION RESULT:', deepSort(mutationResult, 'id')); |
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.
Remove debug logging: Remove the console.log in the pf2 test (BFI2 MUTATION RESULT) if not needed.
| console.log('BFI2 MUTATION RESULT:', deepSort(mutationResult, 'id')); |
| { | ||
| $relation: 'UserTag', | ||
| $op: 'delete', | ||
| $id: ['bfi2-test-tag', 'bfi2-test-tag-1', 'bfi2-test-tag-2'], |
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 appears that the deletion array includes the id 'bfi2-test-tag', but only 'bfi2-test-tag-1' and 'bfi2-test-tag-2' are created. Is 'bfi2-test-tag' a typo, and should it be removed or corrected?
| $id: ['bfi2-test-tag', 'bfi2-test-tag-1', 'bfi2-test-tag-2'], | |
| $id: ['bfi2-test-tag-1', 'bfi2-test-tag-2'], |
Important
Enhance
buildSURQLMutationto handle$tempIdin metadata, update Docker command to--strictmode, and add test cases for mutation outputs with$fields.build.ts,buildSURQLMutationnow processes$tempIdin metadata, converting it to'_:'format.OUTPUTstring to includemetaStringwith$tempIdhandling.test.sh, Docker command updated to use--strictmode for SurrealDB.basic.tsto test mutation outputs with$fields.basic.tsfor debugging purposes.This description was created by
for fd0e38b. You can customize this summary. It will automatically update as commits are pushed.