chore: cloudcmd: actions: lint ☘️

This commit is contained in:
coderaiser 2024-03-22 21:03:18 +00:00
parent f5f34a85ea
commit bf2e8f9a7d
4 changed files with 7 additions and 3 deletions

View file

@ -8,9 +8,11 @@ import cloudcmd from '../../server/cloudcmd.mjs';
const __filename = fileURLToPath(import.meta.url);
const __dirname = dirname(__filename);
const config = {
root: new URL('..', import.meta.url).pathname,
};
const configManager = cloudcmd.createConfigManager();
configManager('auth', false);
@ -18,6 +20,7 @@ const {request} = serveOnce(cloudcmd, {
config,
configManager,
});
const fixtureDir = join(__dirname, '..', 'fixture') + '/';
test('cloudcmd: rest: copy', async (t) => {

View file

@ -1,10 +1,8 @@
import {createRequire} from 'node:module';
import {dirname, join} from 'node:path';
import {fileURLToPath} from 'node:url';
import serveOnce from 'serve-once';
import {test, stub} from 'supertape';
import cloudcmd from '../../server/cloudcmd.mjs';
const __filename = fileURLToPath(import.meta.url);
@ -15,6 +13,7 @@ const cloudcmdPath = join(__dirname, '..', '..');
const modulesPath = join(cloudcmdPath, 'json', 'modules.json');
const localModules = require(modulesPath);
const modulas = require(`../../server/modulas`);
const {request} = serveOnce(cloudcmd, {
config: {
auth: false,

View file

@ -6,9 +6,11 @@ import cloudcmd from '../server/cloudcmd.mjs';
const config = {
auth: false,
};
const {request} = serveOnce(cloudcmd, {
config,
});
const configFn = cloudcmd.createConfigManager();
test('cloudcmd: static', async (t) => {