snap-shot icon indicating copy to clipboard operation
snap-shot copied to clipboard

composed snapshot

Open bahmutov opened this issue 8 years ago • 1 comments

Does not find the right source location if the snapshot was used in composition, for example src/format-spec.js

const compose = (f, g) => x => f(g(x))
const upperCase = x => x.toUpperCase()
const upValue = compose(snapshot, upperCase)
it('compares upper case string', () => {
  upValue('foo')
})

Should find upValue call

bahmutov avatar Feb 07 '17 06:02 bahmutov

Need to make sure it can discover the desired function to handle multiple values

it('compares multiple upper case values', () => {
  upValue('foo')
  upValue('bar')
  upValue('baz')
})

Currently is looking for hardcoded string snapshot which does not work.

bahmutov avatar Feb 07 '17 06:02 bahmutov