You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

12 rivejä
461 B

  1. import path from 'node:path'
  2. export function matchesSceneScreenshotAttachment(file, attachment) {
  3. const stem = file.replace(/\.[^.]+$/, '')
  4. const attachmentFile = path.basename(String(attachment.path || '').replaceAll('\\', '/'))
  5. return attachment.name === file || attachment.name === stem || attachmentFile === file
  6. }
  7. export function isSceneUnitProof(proof) {
  8. return ['api', 'unit', 'contract', 'integration', 'manual-visual'].includes(proof.kind)
  9. }