import { matcherHint , printExpected , printReceived } from 'jest-matcher-utils' ; /**
 * Abstract class for writing asymmetric matchers
 */ export abstract class AsymmetricMatcher < T > implements jest . AsymmetricMatcher { $$typeof : symbol ; inverse ? : boolean ; protected actual : T ; protected constructor ( actual ) { this . $$typeof = Symbol . for ( 'jest.asymmetricMatcher' ) ; this . actual = actual ; } toAsymmetricMatcher ( ) { return `${ this . toString ( ) }<${ this . actual }>` ; } protected passMessage = ( actual , expected ) => ( ) : string => `${ matcherHint ( `.not.${ this . method ( ) }` ) }

Expected value not to match:
  ${ printExpected ( expected ) }
Received:
  ${ printReceived ( actual ) }` ; protected failMessage = ( actual , expected ) => ( ) : string => `${ matcherHint ( `.${ this . method ( ) }` ) }

Expected value to match:
  ${ printExpected ( expected ) }
Received:
  ${ printReceived ( actual ) }` ; abstract method ( ) ; abstract asymmetricMatch ( other ) ; abstract match ( other ? ) ; }