const key = fc.string16bits();
const values = [ key, fc.boolean(), fc.integer(), fc.double(), fc.constantFrom(null, Number.NEGATIVE_INFINITY, Number.POSITIVE_INFINITY/*, Number.NaN*/) ];
const yamlArbitrary = fc.object({ key: key, values: values });
const styleArbitrary = fc.record({
'!!null': fc.constantFrom('lowercase', 'canonical', 'uppercase', 'camelcase'),
'!!int': fc.constantFrom('decimal', 'binary', 'octal', 'hexadecimal'),
'!!bool': fc.constantFrom('lowercase', 'uppercase', 'camelcase'),
'!!float': fc.constantFrom('lowercase', 'uppercase', 'camelcase'),
}, {with_deleted_keys: true});
const optionsArbitrary = fc.record({
skipInvalid: fc.boolean(),
sortKeys: fc.boolean(),
noRefs: fc.boolean(),
noCompatMode: fc.boolean(),
condenseFlow: fc.boolean(),
indent: fc.integer(1, 80),
flowLevel: fc.integer(-1, 10),
styles: styleArbitrary,
}, {with_deleted_keys: true})
.map(instance => {
if (instance.condenseFlow === true && instance.flowLevel !== undefined)
instance.flowLevel = -1;
return instance;
});