@zeit/schemas
Advanced tools
Comparing version 2.21.0 to 2.22.0
{ | ||
"name": "@zeit/schemas", | ||
"version": "2.21.0", | ||
"version": "2.22.0", | ||
"description": "All schemas used for validation that are shared between our projects", | ||
@@ -5,0 +5,0 @@ "scripts": { |
@@ -297,2 +297,28 @@ /* eslint camelcase: 0 */ | ||
exports.test_viewPreference_cards_valid = () => { | ||
assert(ajv.validate(User, { viewPreference: 'cards' })); | ||
}; | ||
exports.test_viewPreference_list_valid = () => { | ||
assert(ajv.validate(User, { viewPreference: 'list' })); | ||
}; | ||
exports.test_viewPreference_null_valid = () => { | ||
assert(ajv.validate(User, { viewPreference: null })); | ||
}; | ||
exports.test_viewPreference_invalid_value = () => { | ||
const isValid = ajv.validate(User, { | ||
viewPreference: 'test' | ||
}); | ||
assert.equal(isValid, false); | ||
}; | ||
exports.test_viewPreference_number_invalid = () => { | ||
const isValid = ajv.validate(User, { | ||
viewPreference: 10 | ||
}); | ||
assert.equal(isValid, false); | ||
}; | ||
exports.test_remoteCaching_valid = () => { | ||
@@ -299,0 +325,0 @@ assert(ajv.validate(User, { remoteCaching: { enabled: true } })); |
@@ -74,2 +74,13 @@ const Username = { | ||
const ViewPreference = { | ||
oneOf: [ | ||
{ | ||
'enum': ['cards', 'list'] | ||
}, | ||
{ | ||
type: 'null' | ||
} | ||
] | ||
}; | ||
const PlatformVersion = { | ||
@@ -170,2 +181,3 @@ oneOf: [ | ||
gitNamespaceId: GitNamespaceId, | ||
viewPreference: ViewPreference, | ||
remoteCaching: RemoteCaching, | ||
@@ -188,3 +200,4 @@ dismissedToasts: DismissedToasts | ||
GitNamespaceId, | ||
ViewPreference, | ||
DismissedToasts | ||
}; |
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
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
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
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
29514
1172