mirror of
https://github.com/mountain-loop/yaak.git
synced 2026-03-18 07:24:07 +01:00
Migrate to Vite+ unified toolchain (#428)
This commit is contained in:
@@ -7,7 +7,7 @@
|
||||
"scripts": {
|
||||
"build": "yaakcli build",
|
||||
"dev": "yaakcli dev",
|
||||
"test": "vitest --run tests"
|
||||
"test": "vp test --run tests"
|
||||
},
|
||||
"dependencies": {
|
||||
"openapi-to-postmanv2": "^5.8.0",
|
||||
|
||||
@@ -14,11 +14,11 @@ export const plugin: PluginDefinition = {
|
||||
};
|
||||
|
||||
export async function convertOpenApi(contents: string): Promise<ImportPluginResponse | undefined> {
|
||||
// biome-ignore lint/suspicious/noExplicitAny: none
|
||||
// oxlint-disable-next-line no-explicit-any
|
||||
let postmanCollection: any;
|
||||
try {
|
||||
postmanCollection = await new Promise((resolve, reject) => {
|
||||
// biome-ignore lint/suspicious/noExplicitAny: none
|
||||
// oxlint-disable-next-line no-explicit-any
|
||||
convert({ type: 'string', data: contents }, {}, (err, result: any) => {
|
||||
if (err != null) reject(err);
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import * as fs from 'node:fs';
|
||||
import * as path from 'node:path';
|
||||
import { describe, expect, test } from 'vitest';
|
||||
import { describe, expect, test } from 'vite-plus/test';
|
||||
import { convertOpenApi } from '../src';
|
||||
|
||||
describe('importer-openapi', () => {
|
||||
|
||||
Reference in New Issue
Block a user