@unleash/client-specification
Advanced tools
Comparing version 4.2.2 to 4.3.0
{ | ||
"name": "@unleash/client-specification", | ||
"version": "4.2.2", | ||
"version": "4.3.0", | ||
"description": "A collection of test specifications to guide client implementations in various languages", | ||
@@ -22,5 +22,5 @@ "scripts": { | ||
"chalk": "4.1.2", | ||
"joi": "17.6.0", | ||
"joi": "17.8.1", | ||
"murmurhash3js": "3.0.1" | ||
} | ||
} |
@@ -16,2 +16,12 @@ const Joi = require('joi'); | ||
parameters: Joi.object(), | ||
variants: Joi.array().items( | ||
Joi.object().keys({ | ||
name: Joi.string().required(), | ||
payload: Joi.object().required().keys({ | ||
type: Joi.string().required(), | ||
value: Joi.string().required().allow(""), | ||
}).optional(), | ||
weight: Joi.number().min(0).max(100000), | ||
stickiness: Joi.string().optional(), | ||
})).optional(), | ||
constraints: Joi.array().items( | ||
@@ -18,0 +28,0 @@ Joi.object().keys({ |
@@ -171,2 +171,14 @@ { | ||
] | ||
}, | ||
{ | ||
"name": "Feature.Variants.F", | ||
"description": "Empty variants", | ||
"enabled": true, | ||
"strategies": [ | ||
{ | ||
"name": "default", | ||
"parameters": {} | ||
} | ||
], | ||
"variants": [] | ||
} | ||
@@ -375,4 +387,15 @@ ] | ||
} | ||
}, | ||
{ | ||
"description": "Feature.Variants.F should be disabled when variants are empty", | ||
"context": { | ||
"userId": "0" | ||
}, | ||
"toggleName": "Feature.Variants.F", | ||
"expectedResult": { | ||
"name": "disabled", | ||
"enabled": false | ||
} | ||
} | ||
] | ||
} |
@@ -56,3 +56,3 @@ { | ||
"operator": "STR_ENDS_WITH", | ||
"values": ["@some-email.com"] | ||
"values": ["some-email.com"] | ||
} | ||
@@ -75,3 +75,3 @@ ] | ||
"operator": "STR_ENDS_WITH", | ||
"values": ["@some-email.com"], | ||
"values": ["some-email.com"], | ||
"caseInsensitive": true | ||
@@ -456,3 +456,3 @@ } | ||
"properties": { | ||
"email": "@some-email.com" | ||
"email": "test@some-email.com" | ||
} | ||
@@ -467,3 +467,3 @@ }, | ||
"properties": { | ||
"email": "@some-EMAIL.com" | ||
"email": "test@some-EMAIL.com" | ||
} | ||
@@ -478,3 +478,3 @@ }, | ||
"properties": { | ||
"email": "@SOME-EMAIL.com" | ||
"email": "test@SOME-EMAIL.com" | ||
} | ||
@@ -489,3 +489,3 @@ }, | ||
"properties": { | ||
"email": "@another-email.com" | ||
"email": "test@another-email.com" | ||
} | ||
@@ -500,3 +500,3 @@ }, | ||
"properties": { | ||
"email": "@some-email.com" | ||
"email": "test@some-email.com" | ||
} | ||
@@ -511,3 +511,3 @@ }, | ||
"properties": { | ||
"email": "@another.com" | ||
"email": "test@another.com" | ||
} | ||
@@ -522,3 +522,3 @@ }, | ||
"properties": { | ||
"email": "@another.com" | ||
"email": "test@another.com" | ||
} | ||
@@ -525,0 +525,0 @@ }, |
@@ -16,3 +16,4 @@ [ | ||
"14-constraint-semver-operators.json", | ||
"15-global-constraints.json" | ||
"15-global-constraints.json", | ||
"16-strategy-variants.json" | ||
] |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
131107
30
3681