@blazediff/vitest 1.0.1 → 1.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -0
- package/dist/index.js +1 -1
- package/dist/index.mjs +1 -1
- package/package.json +2 -2
package/README.md
CHANGED
package/dist/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
'use strict';Object.defineProperty(exports,'__esModule',{value:true});var matcher=require('@blazediff/matcher'),vitest=require('vitest');function n(){vitest.expect.extend({async toMatchImageSnapshot(r,s){let p=this.testPath||"",a=this.currentTestName||"unknown",t=this.snapshotState,
|
|
1
|
+
'use strict';Object.defineProperty(exports,'__esModule',{value:true});var matcher=require('@blazediff/matcher'),vitest=require('vitest');function n(){vitest.expect.extend({async toMatchImageSnapshot(r,s){let p=this.testPath||"",a=this.currentTestName||"unknown",t=this.snapshotState,o=s?.updateSnapshots??t?._updateSnapshot??(process.env.VITEST_UPDATE_SNAPSHOTS==="true"||"new"),e=await matcher.getOrCreateSnapshot(r,{method:"core",...s,updateSnapshots:o,updateCommand:"-u or VITEST_UPDATE_SNAPSHOTS=true"},{testPath:p,testName:a});if(t&&e.snapshotStatus)switch(e.snapshotStatus){case "added":t.added.increment(a),t._dirty=true;break;case "updated":t.updated.increment(a),t._dirty=true;break;case "matched":t.matched.increment(a);break;case "failed":t.unmatched.increment(a);break}return {pass:e.pass,message:()=>e.message,actual:e.receivedPath,expected:e.baselinePath}}});}n();var m=n;exports.default=m;exports.setupBlazediffMatchers=n;
|
package/dist/index.mjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import {getOrCreateSnapshot}from'@blazediff/matcher';import {expect}from'vitest';function n(){expect.extend({async toMatchImageSnapshot(r,s){let p=this.testPath||"",a=this.currentTestName||"unknown",t=this.snapshotState,
|
|
1
|
+
import {getOrCreateSnapshot}from'@blazediff/matcher';import {expect}from'vitest';function n(){expect.extend({async toMatchImageSnapshot(r,s){let p=this.testPath||"",a=this.currentTestName||"unknown",t=this.snapshotState,o=s?.updateSnapshots??t?._updateSnapshot??(process.env.VITEST_UPDATE_SNAPSHOTS==="true"||"new"),e=await getOrCreateSnapshot(r,{method:"core",...s,updateSnapshots:o,updateCommand:"-u or VITEST_UPDATE_SNAPSHOTS=true"},{testPath:p,testName:a});if(t&&e.snapshotStatus)switch(e.snapshotStatus){case "added":t.added.increment(a),t._dirty=true;break;case "updated":t.updated.increment(a),t._dirty=true;break;case "matched":t.matched.increment(a);break;case "failed":t.unmatched.increment(a);break}return {pass:e.pass,message:()=>e.message,actual:e.receivedPath,expected:e.baselinePath}}});}n();var m=n;export{m as default,n as setupBlazediffMatchers};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@blazediff/vitest",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.1.1",
|
|
4
4
|
"description": "Vitest matcher for visual regression testing with blazediff",
|
|
5
5
|
"private": false,
|
|
6
6
|
"publishConfig": {
|
|
@@ -33,7 +33,7 @@
|
|
|
33
33
|
"homepage": "https://blazediff.dev",
|
|
34
34
|
"license": "MIT",
|
|
35
35
|
"dependencies": {
|
|
36
|
-
"@blazediff/matcher": "1.
|
|
36
|
+
"@blazediff/matcher": "1.1.1"
|
|
37
37
|
},
|
|
38
38
|
"devDependencies": {
|
|
39
39
|
"@types/node": "^24.3.0",
|