test-mixer 4.1.11 → 4.1.12

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.
@@ -1,10 +1,10 @@
1
1
  /**
2
2
  * @name test-mixer
3
3
  * @fileoverview Test helper to generate function opts object variations
4
- * @version 4.1.11
4
+ * @version 4.1.12
5
5
  * @author Roy Revelt, Codsen Ltd
6
6
  * @license MIT
7
7
  * {@link https://codsen.com/os/test-mixer/}
8
8
  */
9
9
 
10
- import{combinations as u}from"object-boolean-combinations";import m from"rfdc";var i="4.1.11";var l=m(),h=i;function j(o={},t={}){if(o&&typeof o!="object")throw new Error("test-mixer: [THROW_ID_01] the first input arg is missing!");if(t&&typeof t!="object")throw new Error("test-mixer: [THROW_ID_02] the second input arg is missing!");let s;if(typeof o=="object"&&typeof t=="object"&&Object.keys(o).filter(e=>typeof o[e]=="boolean").some(e=>Object.keys(t).includes(e)?!1:(s=e,!0)))throw new Error(`test-mixer: [THROW_ID_03] the second input arg object should be defaults; it should be a superset of 1st input arg object. However, 1st input arg object contains key "${s}" which 2nd input arg object doesn't have.`);if(!Object.keys(t).length)return[];let c=l(o),n=l(t),r={};return Object.keys(t).forEach(e=>{typeof n[e]=="boolean"&&!Object.keys(o).includes(e)&&(r[e]=n[e])}),u(r).map(e=>({...t,...c,...e}))}export{j as mixer,h as version};
10
+ import{combinations as u}from"object-boolean-combinations";import m from"rfdc";var i="4.1.12";var l=m(),h=i;function j(o={},t={}){if(o&&typeof o!="object")throw new Error("test-mixer: [THROW_ID_01] the first input arg is missing!");if(t&&typeof t!="object")throw new Error("test-mixer: [THROW_ID_02] the second input arg is missing!");let s;if(typeof o=="object"&&typeof t=="object"&&Object.keys(o).filter(e=>typeof o[e]=="boolean").some(e=>Object.keys(t).includes(e)?!1:(s=e,!0)))throw new Error(`test-mixer: [THROW_ID_03] the second input arg object should be defaults; it should be a superset of 1st input arg object. However, 1st input arg object contains key "${s}" which 2nd input arg object doesn't have.`);if(!Object.keys(t).length)return[];let c=l(o),n=l(t),r={};return Object.keys(t).forEach(e=>{typeof n[e]=="boolean"&&!Object.keys(o).includes(e)&&(r[e]=n[e])}),u(r).map(e=>({...t,...c,...e}))}export{j as mixer,h as version};
@@ -1,17 +1,17 @@
1
1
  /**
2
2
  * @name test-mixer
3
3
  * @fileoverview Test helper to generate function opts object variations
4
- * @version 4.1.11
4
+ * @version 4.1.12
5
5
  * @author Roy Revelt, Codsen Ltd
6
6
  * @license MIT
7
7
  * {@link https://codsen.com/os/test-mixer/}
8
8
  */
9
9
 
10
- "use strict";var testMixer=(()=>{var T=Object.create;var y=Object.defineProperty;var N=Object.getOwnPropertyDescriptor;var V=Object.getOwnPropertyNames,j=Object.getOwnPropertySymbols,_=Object.getPrototypeOf,D=Object.prototype.hasOwnProperty,I=Object.prototype.propertyIsEnumerable;var v=(r,t,o)=>t in r?y(r,t,{enumerable:!0,configurable:!0,writable:!0,value:o}):r[t]=o,h=(r,t)=>{for(var o in t||(t={}))D.call(t,o)&&v(r,o,t[o]);if(j)for(var o of j(t))I.call(t,o)&&v(r,o,t[o]);return r};var L=(r,t)=>()=>(t||r((t={exports:{}}).exports,t),t.exports),W=(r,t)=>{for(var o in t)y(r,o,{get:t[o],enumerable:!0})},O=(r,t,o,f)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of V(t))!D.call(r,i)&&i!==o&&y(r,i,{get:()=>t[i],enumerable:!(f=N(t,i))||f.enumerable});return r};var A=(r,t,o)=>(o=r!=null?T(_(r)):{},O(t||!r||!r.__esModule?y(o,"default",{value:r,enumerable:!0}):o,r)),F=r=>O(y({},"__esModule",{value:!0}),r);var g=L((G,x)=>{"use strict";x.exports=H;function b(r){return r instanceof Buffer?Buffer.from(r):new r.constructor(r.buffer.slice(),r.byteOffset,r.length)}function H(r){if(r=r||{},r.circles)return J(r);return r.proto?f:o;function t(i,a){for(var n=Object.keys(i),e=new Array(n.length),l=0;l<n.length;l++){var s=n[l],u=i[s];typeof u!="object"||u===null?e[s]=u:u instanceof Date?e[s]=new Date(u):ArrayBuffer.isView(u)?e[s]=b(u):e[s]=a(u)}return e}function o(i){if(typeof i!="object"||i===null)return i;if(i instanceof Date)return new Date(i);if(Array.isArray(i))return t(i,o);if(i instanceof Map)return new Map(t(Array.from(i),o));if(i instanceof Set)return new Set(t(Array.from(i),o));var a={};for(var n in i)if(Object.hasOwnProperty.call(i,n)!==!1){var e=i[n];typeof e!="object"||e===null?a[n]=e:e instanceof Date?a[n]=new Date(e):e instanceof Map?a[n]=new Map(t(Array.from(e),o)):e instanceof Set?a[n]=new Set(t(Array.from(e),o)):ArrayBuffer.isView(e)?a[n]=b(e):a[n]=o(e)}return a}function f(i){if(typeof i!="object"||i===null)return i;if(i instanceof Date)return new Date(i);if(Array.isArray(i))return t(i,f);if(i instanceof Map)return new Map(t(Array.from(i),f));if(i instanceof Set)return new Set(t(Array.from(i),f));var a={};for(var n in i){var e=i[n];typeof e!="object"||e===null?a[n]=e:e instanceof Date?a[n]=new Date(e):e instanceof Map?a[n]=new Map(t(Array.from(e),f)):e instanceof Set?a[n]=new Set(t(Array.from(e),f)):ArrayBuffer.isView(e)?a[n]=b(e):a[n]=f(e)}return a}}function J(r){var t=[],o=[];return r.proto?a:i;function f(n,e){for(var l=Object.keys(n),s=new Array(l.length),u=0;u<l.length;u++){var p=l[u],c=n[p];if(typeof c!="object"||c===null)s[p]=c;else if(c instanceof Date)s[p]=new Date(c);else if(ArrayBuffer.isView(c))s[p]=b(c);else{var m=t.indexOf(c);m!==-1?s[p]=o[m]:s[p]=e(c)}}return s}function i(n){if(typeof n!="object"||n===null)return n;if(n instanceof Date)return new Date(n);if(Array.isArray(n))return f(n,i);if(n instanceof Map)return new Map(f(Array.from(n),i));if(n instanceof Set)return new Set(f(Array.from(n),i));var e={};t.push(n),o.push(e);for(var l in n)if(Object.hasOwnProperty.call(n,l)!==!1){var s=n[l];if(typeof s!="object"||s===null)e[l]=s;else if(s instanceof Date)e[l]=new Date(s);else if(s instanceof Map)e[l]=new Map(f(Array.from(s),i));else if(s instanceof Set)e[l]=new Set(f(Array.from(s),i));else if(ArrayBuffer.isView(s))e[l]=b(s);else{var u=t.indexOf(s);u!==-1?e[l]=o[u]:e[l]=i(s)}}return t.pop(),o.pop(),e}function a(n){if(typeof n!="object"||n===null)return n;if(n instanceof Date)return new Date(n);if(Array.isArray(n))return f(n,a);if(n instanceof Map)return new Map(f(Array.from(n),a));if(n instanceof Set)return new Set(f(Array.from(n),a));var e={};t.push(n),o.push(e);for(var l in n){var s=n[l];if(typeof s!="object"||s===null)e[l]=s;else if(s instanceof Date)e[l]=new Date(s);else if(s instanceof Map)e[l]=new Map(f(Array.from(s),a));else if(s instanceof Set)e[l]=new Set(f(Array.from(s),a));else if(ArrayBuffer.isView(s))e[l]=b(s);else{var u=t.indexOf(s);u!==-1?e[l]=o[u]:e[l]=a(s)}}return t.pop(),o.pop(),e}}});var Z={};W(Z,{mixer:()=>q,version:()=>U});var S=A(g(),1);var K=(0,S.default)();function d(r){if(r==null||typeof r!="object")return!1;let t=Object.getPrototypeOf(r);return t!==null&&t!==Object.prototype&&Object.getPrototypeOf(t)!==null?!1:!(Symbol.iterator in r)&&!(Symbol.toStringTag in r)}function C(r=[],t=[]){return!r||!t?[]:Array.from(new Set(Array.from(r).filter(o=>new Set(t).has(o))))}var $=A(g(),1);var E=(0,$.default)();function B(r,t={}){function o(u){let p=[];for(let c=0;c<1<<u;c++){let m=[];for(let w=0;w<u;w++)m.push(c&1<<w?1:0);p.push(m)}return p}if(!r)throw new Error("[THROW_ID_01] missing input object");if(!d(r))throw new Error("[THROW_ID_02] the first input object must be a plain object");if(t&&!d(t))throw new Error("[THROW_ID_03] the second override object must be a plain object");let f=E(r),i=E(t),a=Object.keys(f),n=[],e=[];d(i)&&Object.keys(i).length&&(e=C(Object.keys(i),Object.keys(f)),a=a.filter(u=>!e.includes(u)));let l=o(Object.keys(a).length),s;return l.forEach((u,p)=>{s={},a.forEach((c,m)=>{s[c]=l[p][m]===1}),n.push(s)}),d(i)&&Object.keys(i).length&&n.forEach(u=>{e.forEach(p=>{u[p]=i[p]})}),n}var P=A(g(),1);var M="4.1.11";var R=(0,P.default)(),U=M;function q(r={},t={}){if(r&&typeof r!="object")throw new Error("test-mixer: [THROW_ID_01] the first input arg is missing!");if(t&&typeof t!="object")throw new Error("test-mixer: [THROW_ID_02] the second input arg is missing!");let o;if(typeof r=="object"&&typeof t=="object"&&Object.keys(r).filter(e=>typeof r[e]=="boolean").some(e=>Object.keys(t).includes(e)?!1:(o=e,!0)))throw new Error(`test-mixer: [THROW_ID_03] the second input arg object should be defaults; it should be a superset of 1st input arg object. However, 1st input arg object contains key "${o}" which 2nd input arg object doesn't have.`);if(!Object.keys(t).length)return[];let f=R(r),i=R(t),a={};return Object.keys(t).forEach(e=>{typeof i[e]=="boolean"&&!Object.keys(r).includes(e)&&(a[e]=i[e])}),B(a).map(e=>h(h(h({},t),f),e))}return F(Z);})();
10
+ "use strict";var testMixer=(()=>{var T=Object.create;var y=Object.defineProperty;var N=Object.getOwnPropertyDescriptor;var V=Object.getOwnPropertyNames,j=Object.getOwnPropertySymbols,_=Object.getPrototypeOf,D=Object.prototype.hasOwnProperty,I=Object.prototype.propertyIsEnumerable;var v=(r,t,o)=>t in r?y(r,t,{enumerable:!0,configurable:!0,writable:!0,value:o}):r[t]=o,h=(r,t)=>{for(var o in t||(t={}))D.call(t,o)&&v(r,o,t[o]);if(j)for(var o of j(t))I.call(t,o)&&v(r,o,t[o]);return r};var L=(r,t)=>()=>(t||r((t={exports:{}}).exports,t),t.exports),W=(r,t)=>{for(var o in t)y(r,o,{get:t[o],enumerable:!0})},O=(r,t,o,f)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of V(t))!D.call(r,i)&&i!==o&&y(r,i,{get:()=>t[i],enumerable:!(f=N(t,i))||f.enumerable});return r};var A=(r,t,o)=>(o=r!=null?T(_(r)):{},O(t||!r||!r.__esModule?y(o,"default",{value:r,enumerable:!0}):o,r)),F=r=>O(y({},"__esModule",{value:!0}),r);var g=L((G,x)=>{"use strict";x.exports=H;function b(r){return r instanceof Buffer?Buffer.from(r):new r.constructor(r.buffer.slice(),r.byteOffset,r.length)}function H(r){if(r=r||{},r.circles)return J(r);return r.proto?f:o;function t(i,a){for(var n=Object.keys(i),e=new Array(n.length),l=0;l<n.length;l++){var s=n[l],u=i[s];typeof u!="object"||u===null?e[s]=u:u instanceof Date?e[s]=new Date(u):ArrayBuffer.isView(u)?e[s]=b(u):e[s]=a(u)}return e}function o(i){if(typeof i!="object"||i===null)return i;if(i instanceof Date)return new Date(i);if(Array.isArray(i))return t(i,o);if(i instanceof Map)return new Map(t(Array.from(i),o));if(i instanceof Set)return new Set(t(Array.from(i),o));var a={};for(var n in i)if(Object.hasOwnProperty.call(i,n)!==!1){var e=i[n];typeof e!="object"||e===null?a[n]=e:e instanceof Date?a[n]=new Date(e):e instanceof Map?a[n]=new Map(t(Array.from(e),o)):e instanceof Set?a[n]=new Set(t(Array.from(e),o)):ArrayBuffer.isView(e)?a[n]=b(e):a[n]=o(e)}return a}function f(i){if(typeof i!="object"||i===null)return i;if(i instanceof Date)return new Date(i);if(Array.isArray(i))return t(i,f);if(i instanceof Map)return new Map(t(Array.from(i),f));if(i instanceof Set)return new Set(t(Array.from(i),f));var a={};for(var n in i){var e=i[n];typeof e!="object"||e===null?a[n]=e:e instanceof Date?a[n]=new Date(e):e instanceof Map?a[n]=new Map(t(Array.from(e),f)):e instanceof Set?a[n]=new Set(t(Array.from(e),f)):ArrayBuffer.isView(e)?a[n]=b(e):a[n]=f(e)}return a}}function J(r){var t=[],o=[];return r.proto?a:i;function f(n,e){for(var l=Object.keys(n),s=new Array(l.length),u=0;u<l.length;u++){var p=l[u],c=n[p];if(typeof c!="object"||c===null)s[p]=c;else if(c instanceof Date)s[p]=new Date(c);else if(ArrayBuffer.isView(c))s[p]=b(c);else{var m=t.indexOf(c);m!==-1?s[p]=o[m]:s[p]=e(c)}}return s}function i(n){if(typeof n!="object"||n===null)return n;if(n instanceof Date)return new Date(n);if(Array.isArray(n))return f(n,i);if(n instanceof Map)return new Map(f(Array.from(n),i));if(n instanceof Set)return new Set(f(Array.from(n),i));var e={};t.push(n),o.push(e);for(var l in n)if(Object.hasOwnProperty.call(n,l)!==!1){var s=n[l];if(typeof s!="object"||s===null)e[l]=s;else if(s instanceof Date)e[l]=new Date(s);else if(s instanceof Map)e[l]=new Map(f(Array.from(s),i));else if(s instanceof Set)e[l]=new Set(f(Array.from(s),i));else if(ArrayBuffer.isView(s))e[l]=b(s);else{var u=t.indexOf(s);u!==-1?e[l]=o[u]:e[l]=i(s)}}return t.pop(),o.pop(),e}function a(n){if(typeof n!="object"||n===null)return n;if(n instanceof Date)return new Date(n);if(Array.isArray(n))return f(n,a);if(n instanceof Map)return new Map(f(Array.from(n),a));if(n instanceof Set)return new Set(f(Array.from(n),a));var e={};t.push(n),o.push(e);for(var l in n){var s=n[l];if(typeof s!="object"||s===null)e[l]=s;else if(s instanceof Date)e[l]=new Date(s);else if(s instanceof Map)e[l]=new Map(f(Array.from(s),a));else if(s instanceof Set)e[l]=new Set(f(Array.from(s),a));else if(ArrayBuffer.isView(s))e[l]=b(s);else{var u=t.indexOf(s);u!==-1?e[l]=o[u]:e[l]=a(s)}}return t.pop(),o.pop(),e}}});var Z={};W(Z,{mixer:()=>q,version:()=>U});var S=A(g(),1);var K=(0,S.default)();function d(r){if(r==null||typeof r!="object")return!1;let t=Object.getPrototypeOf(r);return t!==null&&t!==Object.prototype&&Object.getPrototypeOf(t)!==null?!1:!(Symbol.iterator in r)&&!(Symbol.toStringTag in r)}function C(r=[],t=[]){return!r||!t?[]:Array.from(new Set(Array.from(r).filter(o=>new Set(t).has(o))))}var $=A(g(),1);var E=(0,$.default)();function B(r,t={}){function o(u){let p=[];for(let c=0;c<1<<u;c++){let m=[];for(let w=0;w<u;w++)m.push(c&1<<w?1:0);p.push(m)}return p}if(!r)throw new Error("[THROW_ID_01] missing input object");if(!d(r))throw new Error("[THROW_ID_02] the first input object must be a plain object");if(t&&!d(t))throw new Error("[THROW_ID_03] the second override object must be a plain object");let f=E(r),i=E(t),a=Object.keys(f),n=[],e=[];d(i)&&Object.keys(i).length&&(e=C(Object.keys(i),Object.keys(f)),a=a.filter(u=>!e.includes(u)));let l=o(Object.keys(a).length),s;return l.forEach((u,p)=>{s={},a.forEach((c,m)=>{s[c]=l[p][m]===1}),n.push(s)}),d(i)&&Object.keys(i).length&&n.forEach(u=>{e.forEach(p=>{u[p]=i[p]})}),n}var P=A(g(),1);var M="4.1.12";var R=(0,P.default)(),U=M;function q(r={},t={}){if(r&&typeof r!="object")throw new Error("test-mixer: [THROW_ID_01] the first input arg is missing!");if(t&&typeof t!="object")throw new Error("test-mixer: [THROW_ID_02] the second input arg is missing!");let o;if(typeof r=="object"&&typeof t=="object"&&Object.keys(r).filter(e=>typeof r[e]=="boolean").some(e=>Object.keys(t).includes(e)?!1:(o=e,!0)))throw new Error(`test-mixer: [THROW_ID_03] the second input arg object should be defaults; it should be a superset of 1st input arg object. However, 1st input arg object contains key "${o}" which 2nd input arg object doesn't have.`);if(!Object.keys(t).length)return[];let f=R(r),i=R(t),a={};return Object.keys(t).forEach(e=>{typeof i[e]=="boolean"&&!Object.keys(r).includes(e)&&(a[e]=i[e])}),B(a).map(e=>h(h(h({},t),f),e))}return F(Z);})();
11
11
  /**
12
12
  * @name codsen-utils
13
13
  * @fileoverview Various utility functions
14
- * @version 1.6.1
14
+ * @version 1.6.2
15
15
  * @author Roy Revelt, Codsen Ltd
16
16
  * @license MIT
17
17
  * {@link https://codsen.com/os/codsen-utils/}
@@ -19,7 +19,7 @@
19
19
  /**
20
20
  * @name object-boolean-combinations
21
21
  * @fileoverview Consumes a defaults object with booleans, generates all possible variations of it
22
- * @version 6.1.2
22
+ * @version 6.1.3
23
23
  * @author Roy Revelt, Codsen Ltd
24
24
  * @license MIT
25
25
  * {@link https://codsen.com/os/object-boolean-combinations/}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "test-mixer",
3
- "version": "4.1.11",
3
+ "version": "4.1.12",
4
4
  "description": "Test helper to generate function opts object variations",
5
5
  "keywords": [
6
6
  "combinations",
@@ -68,7 +68,7 @@
68
68
  }
69
69
  },
70
70
  "dependencies": {
71
- "object-boolean-combinations": "^6.1.2",
71
+ "object-boolean-combinations": "^6.1.3",
72
72
  "rfdc": "^1.3.0"
73
73
  }
74
74
  }
package/types/index.d.ts CHANGED
@@ -10,4 +10,4 @@ declare function mixer(
10
10
  defaultsObj?: PlainObject,
11
11
  ): PlainObjectOfBool[];
12
12
 
13
- export { PlainObject, PlainObjectOfBool, mixer, version };
13
+ export { type PlainObject, type PlainObjectOfBool, mixer, version };