mirror of
https://github.com/bknd-io/bknd/
synced 2026-08-03 16:46:00 +00:00
fixes
This commit is contained in:
@@ -50,7 +50,7 @@ export function fieldTestSuite(
|
||||
expect(noConfigField.hasDefault()).toBe(false);
|
||||
expect(noConfigField.getDefault()).toBeUndefined();
|
||||
expect(dflt.hasDefault()).toBe(true);
|
||||
expect(dflt.getDefault()).toBe(config.defaultValue);
|
||||
expect(dflt.getDefault()).toEqual(config.defaultValue);
|
||||
});
|
||||
|
||||
test("isFillable", async () => {
|
||||
@@ -98,9 +98,6 @@ export function fieldTestSuite(
|
||||
test("toJSON", async () => {
|
||||
const _config = {
|
||||
..._requiredConfig,
|
||||
fillable: true,
|
||||
required: false,
|
||||
hidden: false,
|
||||
};
|
||||
|
||||
function fieldJson(field: Field) {
|
||||
@@ -118,7 +115,10 @@ export function fieldTestSuite(
|
||||
|
||||
expect(fieldJson(fillable)).toEqual({
|
||||
type: noConfigField.type,
|
||||
config: _config,
|
||||
config: {
|
||||
..._config,
|
||||
fillable: true,
|
||||
},
|
||||
});
|
||||
|
||||
expect(fieldJson(required)).toEqual({
|
||||
|
||||
Reference in New Issue
Block a user