2023-07-02 15:46:14 +02:00
|
|
|
const test = require('node:test')
|
|
|
|
const assert = require('node:assert/strict')
|
2022-02-19 16:05:21 +01:00
|
|
|
|
|
|
|
const config = require('../index.js')
|
|
|
|
|
2023-07-02 15:46:14 +02:00
|
|
|
/**
|
|
|
|
* @param {unknown} object
|
|
|
|
* @returns {boolean}
|
|
|
|
*/
|
2022-08-31 14:00:08 +02:00
|
|
|
const isObject = (object) => {
|
|
|
|
return typeof object === 'object' && object !== null
|
|
|
|
}
|
|
|
|
|
2023-07-02 15:46:14 +02:00
|
|
|
test('test basic properties of config', async () => {
|
|
|
|
assert.ok(isObject(config))
|
|
|
|
assert.ok(isObject(config.parserOptions))
|
|
|
|
assert.ok(isObject(config.env))
|
|
|
|
assert.ok(isObject(config.rules))
|
|
|
|
assert.ok(isObject(config.overrides))
|
2022-02-19 16:05:21 +01:00
|
|
|
})
|