@@ -562,31 +562,31 @@ public static function provideExceptions(): iterable
562
562
];
563
563
564
564
yield 'where regex not starting with / ' => [
565
- \InvalidArgumentException ::class,
565
+ \LogicException ::class,
566
566
'Regular expressions must be surrounded by delimiter "/". Got "^ac/me$" ' ,
567
567
fn (Builder $ builder ) => $ builder ->where ('name ' , 'regex ' , '^ac/me$ ' ),
568
568
];
569
569
570
570
yield 'where regex not ending with / ' => [
571
- \InvalidArgumentException ::class,
571
+ \LogicException ::class,
572
572
'Regular expressions must be surrounded by delimiter "/". Got "/^acme$" ' ,
573
573
fn (Builder $ builder ) => $ builder ->where ('name ' , 'regex ' , '/^acme$ ' ),
574
574
];
575
575
576
576
yield 'where regex not ending with # ' => [
577
- \InvalidArgumentException ::class,
577
+ \LogicException ::class,
578
578
'Regular expressions must be surrounded by delimiter "#". Got "#^acme$" ' ,
579
579
fn (Builder $ builder ) => $ builder ->where ('name ' , 'regex ' , '#^acme$ ' ),
580
580
];
581
581
582
582
yield 'where regexp not supported ' => [
583
- \InvalidArgumentException ::class,
583
+ \LogicException ::class,
584
584
'Operator "regexp" is not supported. Use "regex" instead. ' ,
585
585
fn (Builder $ builder ) => $ builder ->where ('name ' , 'regexp ' , '/^acme$/ ' ),
586
586
];
587
587
588
588
yield 'where ilike not supported ' => [
589
- \InvalidArgumentException ::class,
589
+ \LogicException ::class,
590
590
'Operator "ilike" is not supported. Use "like" instead. ' ,
591
591
fn (Builder $ builder ) => $ builder ->where ('name ' , 'ilike ' , 'acme ' ),
592
592
];
0 commit comments