0
// Returns Testing [Object object]
describe.skip.each([[{foo: 'abc'}], [{foo: 'bca'}]])('Testing %s', ...
// Returns Testing {foo: 'abc'}
describe.skip.each([[{foo: 'abc'}], [{foo: 'bca'}]])('Testing %o', ...

Is it possible do something like...

// Expect Testing abc
describe.skip.each([[{foo: 'abc'}], [{foo: 'bca'}]])('Testing %o.foo', ...
skyboyer
  • 19,620
  • 7
  • 50
  • 62
FabianoLothor
  • 2,479
  • 4
  • 23
  • 35

1 Answers1

2

I think is not possible with that API but with the second API it is

describe.each`
    column
    ${{ foo: 'abc' }}
    ${{ foo: 'bca' }}
    `
    ('Testing $column.foo', ({ column }) => {
        ...
    })

Update

Sadly you cannot build a template literal programmatically, here's how tagged template literals work The ${expresion}is needed to identify the data you want to pass.

Coding Edgar
  • 1,085
  • 6
  • 19