@@ -72,29 +72,6 @@ test('plugin is required', async () => {
7272 await expect ( runPluginTester ( ) ) . rejects . toThrowErrorMatchingSnapshot ( )
7373} )
7474
75- test ( 'logs when plugin name is not inferable and rethrows errors' , async ( ) => {
76- const error = new Error ( 'hey there' )
77- await expect (
78- runPluginTester ( {
79- plugin : ( ) => {
80- throw error
81- } ,
82- } ) ,
83- ) . rejects . toThrow ( error )
84- expect ( errorSpy ) . toHaveBeenCalledTimes ( 1 )
85- expect ( errorSpy ) . toHaveBeenCalledWith (
86- expect . stringMatching ( / i n f e r .* n a m e .* p l u g i n / ) ,
87- )
88- } )
89-
90- test ( 'assert throws if the plugin name is not inferable' , async ( ) => {
91- await expect (
92- runPluginTester ( {
93- plugin : ( ) => ( { } ) ,
94- } ) ,
95- ) . rejects . toThrowErrorMatchingSnapshot ( )
96- } )
97-
9875test ( 'exists early if no tests are supplied' , async ( ) => {
9976 const { plugin} = getOptions ( )
10077 await runPluginTester ( { plugin} )
@@ -115,16 +92,6 @@ test('accepts a title for the describe block', async () => {
11592 expect ( describeSpy ) . toHaveBeenCalledWith ( title , expect . any ( Function ) )
11693} )
11794
118- test ( 'can infer the plugin name for the describe block' , async ( ) => {
119- const name = 'super-great'
120- const { plugin, tests} = getOptions ( {
121- plugin : ( ) => ( { name, visitor : { } } ) ,
122- } )
123- await runPluginTester ( { plugin, tests} )
124- expect ( describeSpy ) . toHaveBeenCalledTimes ( 1 )
125- expect ( describeSpy ) . toHaveBeenCalledWith ( name , expect . any ( Function ) )
126- } )
127-
12895test ( 'calls describe and test for a group of tests' , async ( ) => {
12996 const pluginName = 'supergirl'
13097 const customTitle = 'some custom title'
0 commit comments