Commit eacb7b6
fix: use SELECT COUNT(1) without VALUE in aggregate serializer test
SELECT VALUE COUNT(1) returns a scalar integer, which cannot be
deserialized as ObjectNode. The ValueUnwrapCosmosItemSerializer
extracts the _value field and tries to convert the integer to
ObjectNode, causing a deserialization failure.
Changed to SELECT COUNT(1) (without VALUE keyword) which returns
an ObjectNode like {"\": 3}, and added an assertion to verify
the count value.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>1 parent 5b407c8 commit eacb7b6
File tree
1 file changed
+5
-1
lines changed- sdk/cosmos/azure-cosmos-tests/src/test/java/com/azure/cosmos
1 file changed
+5
-1
lines changedLines changed: 5 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
764 | 764 | | |
765 | 765 | | |
766 | 766 | | |
| 767 | + | |
| 768 | + | |
| 769 | + | |
767 | 770 | | |
768 | 771 | | |
769 | 772 | | |
770 | 773 | | |
771 | 774 | | |
772 | | - | |
| 775 | + | |
773 | 776 | | |
774 | 777 | | |
775 | 778 | | |
776 | 779 | | |
777 | 780 | | |
778 | 781 | | |
| 782 | + | |
779 | 783 | | |
780 | 784 | | |
781 | 785 | | |
| |||
0 commit comments