File tree Expand file tree Collapse file tree 1 file changed +0
-34
lines changed
Expand file tree Collapse file tree 1 file changed +0
-34
lines changed Original file line number Diff line number Diff line change @@ -3798,40 +3798,6 @@ mod tests {
37983798 use super :: * ;
37993799 use expect_test:: { expect, Expect } ;
38003800
3801- #[ macro_export]
3802- macro_rules! assert_matches {
3803- ( $x: expr, $pat: pat ) => {
3804- {
3805- let val = $x;
3806- if ( !matches!( val, $pat) ) {
3807- eprintln!( "{} ({:?}) does not match pattern {}" , stringify!( $x) , val, stringify!( $pat) ) ;
3808- assert!( false ) ;
3809- }
3810- }
3811- } ;
3812- }
3813-
3814-
3815- #[ track_caller]
3816- fn assert_matches_value ( insn : Option < & Insn > , val : VALUE ) {
3817- match insn {
3818- Some ( Insn :: Const { val : Const :: Value ( spec) } ) => {
3819- assert_eq ! ( * spec, val) ;
3820- }
3821- _ => assert ! ( false , "Expected Const {val}, found {insn:?}" ) ,
3822- }
3823- }
3824-
3825- #[ track_caller]
3826- fn assert_matches_const ( insn : Option < & Insn > , expected : Const ) {
3827- match insn {
3828- Some ( Insn :: Const { val } ) => {
3829- assert_eq ! ( * val, expected, "{val:?} does not match {expected:?}" ) ;
3830- }
3831- _ => assert ! ( false , "Expected Const {expected:?}, found {insn:?}" ) ,
3832- }
3833- }
3834-
38353801 #[ track_caller]
38363802 fn assert_method_hir ( method : & str , hir : Expect ) {
38373803 let iseq = crate :: cruby:: with_rubyvm ( || get_method_iseq ( "self" , method) ) ;
You can’t perform that action at this time.
0 commit comments