mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-08-11 12:30:18 +00:00
fix: update chai types for breaking changes negated property asserts in 4.0 (#42134)
See: https://github.com/chaijs/chai/issues/781
This commit is contained in:
@@ -1694,15 +1694,15 @@ suite('assert', () => {
|
||||
assert.deepProperty(obj, 'foo.bar');
|
||||
assert.notDeepProperty(obj, 'foo.baz');
|
||||
assert.deepPropertyVal(obj, 'foo.bar', 'baz');
|
||||
assert.deepPropertyNotVal(simpleObj, 'foo.bar', 'flow');
|
||||
assert.notDeepPropertyVal(simpleObj, 'foo.bar', 'flow');
|
||||
assert.property(simpleObj, 'baz');
|
||||
assert.deepProperty(obj, 'foo.baz');
|
||||
assert.notProperty(obj, 'foo');
|
||||
assert.notDeepProperty(obj, 'foo.bar');
|
||||
assert.propertyVal(simpleObj, 'foo', 'ball');
|
||||
assert.deepPropertyVal(obj, 'foo.bar', 'ball');
|
||||
assert.propertyNotVal(simpleObj, 'foo', 'bar');
|
||||
assert.deepPropertyNotVal(simpleObj, 'foo.bar', 'baz');
|
||||
assert.notPropertyVal(simpleObj, 'foo', 'bar');
|
||||
assert.notDeepPropertyVal(simpleObj, 'foo.bar', 'baz');
|
||||
});
|
||||
|
||||
test('throws', () => {
|
||||
|
||||
Vendored
+2
-2
@@ -1126,7 +1126,7 @@ declare namespace Chai {
|
||||
* @param value Potential expected property value.
|
||||
* @param message Message to display on error.
|
||||
*/
|
||||
propertyNotVal<T, V>(object: T, property: string /* keyof T */, value: V, message?: string): void;
|
||||
notPropertyVal<T, V>(object: T, property: string /* keyof T */, value: V, message?: string): void;
|
||||
|
||||
/**
|
||||
* Asserts that object has a property named by property, which can be a string
|
||||
@@ -1152,7 +1152,7 @@ declare namespace Chai {
|
||||
* @param value Potential expected property value.
|
||||
* @param message Message to display on error.
|
||||
*/
|
||||
deepPropertyNotVal<T, V>(object: T, property: string, value: V, message?: string): void;
|
||||
notDeepPropertyVal<T, V>(object: T, property: string, value: V, message?: string): void;
|
||||
|
||||
/**
|
||||
* Asserts that object has a length property with the expected value.
|
||||
|
||||
Reference in New Issue
Block a user