@@ -695,79 +695,30 @@ await SetupAndRunRestApiTest(
695695
696696 /// <summary>
697697 /// Tests the REST Api for Find operation with a filter containing special characters
698- /// like ampersand (&) that need to be URL-encoded. This validates that the fix for
699- /// the double-decoding issue is working correctly.
698+ /// that need to be URL-encoded. Uses existing book with '%' character (SOME%CONN).
699+ /// This validates that the fix for the double-decoding issue is working correctly.
700700 /// </summary>
701701 [ TestMethod ]
702702 public async Task FindTestWithFilterContainingSpecialCharacters ( )
703703 {
704+ // Testing with SOME%CONN - the %25 is URL-encoded %
704705 await SetupAndRunRestApiTest (
705706 primaryKeyRoute : string . Empty ,
706- queryString : "?$filter=title%20eq%20%27filter%20%26%20test %27" ,
707+ queryString : "?$filter=title%20eq%20%27SOME%25CONN %27" ,
707708 entityNameOrPath : _integrationEntityName ,
708709 sqlQuery : GetQuery ( nameof ( FindTestWithFilterContainingSpecialCharacters ) )
709710 ) ;
710711 }
711712
712713 /// <summary>
713- /// Tests the REST Api for Find operation with filters containing various special characters
714- /// that need URL encoding: plus (+), equals (=), and percent (%).
715- /// Validates that multiple types of special characters are handled correctly.
716- /// </summary>
717- [ TestMethod ]
718- public async Task FindTestWithFilterContainingMultipleSpecialCharacters ( )
719- {
720- // Test with plus and equals signs - URL-encoded
721- await SetupAndRunRestApiTest (
722- primaryKeyRoute : string . Empty ,
723- queryString : "?$filter=title%20eq%20%27A%2BB%3DC%27" ,
724- entityNameOrPath : _integrationEntityName ,
725- sqlQuery : GetQuery ( nameof ( FindTestWithFilterContainingMultipleSpecialCharacters ) )
726- ) ;
727- }
728-
729- /// <summary>
730- /// Tests the REST Api for Find operation with a filter containing ampersand
731- /// in a different context to ensure robustness across various data patterns.
732- /// </summary>
733- [ TestMethod ]
734- public async Task FindTestWithFilterContainingAmpersandInPhrase ( )
735- {
736- await SetupAndRunRestApiTest (
737- primaryKeyRoute : string . Empty ,
738- queryString : "?$filter=title%20eq%20%27Tom%20%26%20Jerry%27" ,
739- entityNameOrPath : _integrationEntityName ,
740- sqlQuery : GetQuery ( nameof ( FindTestWithFilterContainingAmpersandInPhrase ) )
741- ) ;
742- }
743-
744- /// <summary>
745- /// Tests the REST Api for Find operation with a filter containing percent sign (%)
746- /// which has special meaning in URL encoding and SQL LIKE patterns.
747- /// </summary>
748- [ TestMethod ]
749- public async Task FindTestWithFilterContainingPercentSign ( )
750- {
751- await SetupAndRunRestApiTest (
752- primaryKeyRoute : string . Empty ,
753- queryString : "?$filter=title%20eq%20%27100%25%20Complete%27" ,
754- entityNameOrPath : _integrationEntityName ,
755- sqlQuery : GetQuery ( nameof ( FindTestWithFilterContainingPercentSign ) )
756- ) ;
757- }
758-
759- /// <summary>
760- /// Tests the REST Api for Find operation with an $orderby clause containing special characters.
761- /// When column names or values in orderby contain special characters like spaces that need
762- /// URL encoding, this validates the fix preserves the encoding correctly.
763- /// Note: While this test uses 'title' (which has special chars in values not the column name),
764- /// it validates that $orderby parameter extraction preserves URL encoding through the same
714+ /// Tests the REST Api for Find operation with an $orderby clause containing URL-encoded spaces.
715+ /// This validates that $orderby parameter extraction preserves URL encoding through the same
765716 /// code path as $filter.
766717 /// </summary>
767718 [ TestMethod ]
768719 public async Task FindTestWithOrderByContainingSpecialCharacters ( )
769720 {
770- // Order by title - tests that $orderby parameter is extracted with URL encoding preserved
721+ // Order by title desc - tests that $orderby parameter is extracted with URL encoding preserved
771722 // The %20 represents space in "$orderby=title%20desc"
772723 await SetupAndRunRestApiTest (
773724 primaryKeyRoute : string . Empty ,
0 commit comments