@@ -113,6 +113,15 @@ describe("Search", () => {
113
113
let searchResults = searchService . findNotesWithQuery ( '#capital=Vienna' , searchContext ) ;
114
114
expect ( searchResults . length ) . toEqual ( 1 ) ;
115
115
expect ( findNoteByTitle ( searchResults , "Austria" ) ) . toBeTruthy ( ) ;
116
+
117
+ // case sensitivity:
118
+ searchResults = searchService . findNotesWithQuery ( '#CAPITAL=VIENNA' , searchContext ) ;
119
+ expect ( searchResults . length ) . toEqual ( 1 ) ;
120
+ expect ( findNoteByTitle ( searchResults , "Austria" ) ) . toBeTruthy ( ) ;
121
+
122
+ searchResults = searchService . findNotesWithQuery ( '#caPItal=vienNa' , searchContext ) ;
123
+ expect ( searchResults . length ) . toEqual ( 1 ) ;
124
+ expect ( findNoteByTitle ( searchResults , "Austria" ) ) . toBeTruthy ( ) ;
116
125
} ) ;
117
126
118
127
it ( "label comparison with full syntax" , ( ) => {
@@ -473,13 +482,16 @@ describe("Search", () => {
473
482
}
474
483
475
484
test ( "type" , "text" , 7 ) ;
485
+ test ( "TYPE" , "TEXT" , 7 ) ;
476
486
test ( "type" , "code" , 0 ) ;
477
487
478
488
test ( "mime" , "text/html" , 6 ) ;
479
489
test ( "mime" , "application/json" , 0 ) ;
480
490
481
491
test ( "isProtected" , "false" , 7 ) ;
492
+ test ( "isProtected" , "FALSE" , 7 ) ;
482
493
test ( "isProtected" , "true" , 0 ) ;
494
+ test ( "isProtected" , "TRUE" , 0 ) ;
483
495
484
496
test ( "dateCreated" , "'2020-05-14 12:11:42.001+0200'" , 1 ) ;
485
497
test ( "dateCreated" , "wrong" , 0 ) ;
0 commit comments