test: fix imports after eslint config changes
This commit is contained in:
parent
3dccbfc797
commit
d994c38219
32 changed files with 50 additions and 50 deletions
|
|
@ -1,5 +1,5 @@
|
||||||
import { execFile as execFileOriginal } from "node:child_process";
|
import { execFile as execFileOriginal } from "node:child_process";
|
||||||
import { ExecFileFn } from "./types.ts";
|
import { ExecFileFn } from "./types";
|
||||||
|
|
||||||
export const properties = {
|
export const properties = {
|
||||||
from: {
|
from: {
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
import { execFile as execFileOriginal } from "node:child_process";
|
import { execFile as execFileOriginal } from "node:child_process";
|
||||||
import { ExecFileFn } from "./types.ts";
|
import { ExecFileFn } from "./types";
|
||||||
|
|
||||||
export const properties = {
|
export const properties = {
|
||||||
from: {
|
from: {
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
import { execFile as execFileOriginal } from "node:child_process";
|
import { execFile as execFileOriginal } from "node:child_process";
|
||||||
import { ExecFileFn } from "./types.ts";
|
import { ExecFileFn } from "./types";
|
||||||
|
|
||||||
export const properties = {
|
export const properties = {
|
||||||
from: {
|
from: {
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
import { execFile as execFileOriginal } from "node:child_process";
|
import { execFile as execFileOriginal } from "node:child_process";
|
||||||
import { ExecFileFn } from "./types.ts";
|
import { ExecFileFn } from "./types";
|
||||||
|
|
||||||
// This could be done dynamically by running `ffmpeg -formats` and parsing the output
|
// This could be done dynamically by running `ffmpeg -formats` and parsing the output
|
||||||
export const properties = {
|
export const properties = {
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
import { execFile as execFileOriginal } from "node:child_process";
|
import { execFile as execFileOriginal } from "node:child_process";
|
||||||
import { ExecFileFn } from "./types.ts";
|
import { ExecFileFn } from "./types";
|
||||||
|
|
||||||
export const properties = {
|
export const properties = {
|
||||||
from: {
|
from: {
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
import { execFile as execFileOriginal } from "node:child_process";
|
import { execFile as execFileOriginal } from "node:child_process";
|
||||||
import { ExecFileFn } from "./types.ts";
|
import { ExecFileFn } from "./types";
|
||||||
|
|
||||||
// declare possible conversions
|
// declare possible conversions
|
||||||
export const properties = {
|
export const properties = {
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
import { execFile as execFileOriginal } from "node:child_process";
|
import { execFile as execFileOriginal } from "node:child_process";
|
||||||
import { ExecFileFn } from "./types.ts";
|
import { ExecFileFn } from "./types";
|
||||||
|
|
||||||
export const properties = {
|
export const properties = {
|
||||||
from: {
|
from: {
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
import { execFile as execFileOriginal } from "child_process";
|
import { execFile as execFileOriginal } from "child_process";
|
||||||
import { ExecFileFn } from "./types.ts";
|
import { ExecFileFn } from "./types";
|
||||||
|
|
||||||
export const properties = {
|
export const properties = {
|
||||||
from: {
|
from: {
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
import { execFile as execFileOriginal } from "node:child_process";
|
import { execFile as execFileOriginal } from "node:child_process";
|
||||||
import { ExecFileFn } from "./types.ts";
|
import { ExecFileFn } from "./types";
|
||||||
|
|
||||||
// declare possible conversions
|
// declare possible conversions
|
||||||
export const properties = {
|
export const properties = {
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
import { execFile as execFileOriginal } from "node:child_process";
|
import { execFile as execFileOriginal } from "node:child_process";
|
||||||
import { ExecFileFn } from "./types.ts";
|
import { ExecFileFn } from "./types";
|
||||||
|
|
||||||
export const properties = {
|
export const properties = {
|
||||||
from: {
|
from: {
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
import { execFile as execFileOriginal } from "node:child_process";
|
import { execFile as execFileOriginal } from "node:child_process";
|
||||||
import { ExecFileFn } from "./types.ts";
|
import { ExecFileFn } from "./types";
|
||||||
|
|
||||||
export const properties = {
|
export const properties = {
|
||||||
from: {
|
from: {
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
import { execFile as execFileOriginal } from "node:child_process";
|
import { execFile as execFileOriginal } from "node:child_process";
|
||||||
import { ExecFileFn } from "./types.ts";
|
import { ExecFileFn } from "./types";
|
||||||
|
|
||||||
export const properties = {
|
export const properties = {
|
||||||
from: {
|
from: {
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
import { execFile as execFileOriginal } from "node:child_process";
|
import { execFile as execFileOriginal } from "node:child_process";
|
||||||
import { ExecFileFn } from "./types.ts";
|
import { ExecFileFn } from "./types";
|
||||||
|
|
||||||
export const properties = {
|
export const properties = {
|
||||||
from: {
|
from: {
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
import { execFile as execFileOriginal } from "node:child_process";
|
import { execFile as execFileOriginal } from "node:child_process";
|
||||||
import { ExecFileFn } from "./types.ts";
|
import { ExecFileFn } from "./types";
|
||||||
|
|
||||||
export const properties = {
|
export const properties = {
|
||||||
from: {
|
from: {
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
import { execFile as execFileOriginal } from "node:child_process";
|
import { execFile as execFileOriginal } from "node:child_process";
|
||||||
import { ExecFileFn } from "./types.ts";
|
import { ExecFileFn } from "./types";
|
||||||
|
|
||||||
// declare possible conversions
|
// declare possible conversions
|
||||||
export const properties = {
|
export const properties = {
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
import { execFile as execFileOriginal } from "node:child_process";
|
import { execFile as execFileOriginal } from "node:child_process";
|
||||||
import { ExecFileFn } from "./types.ts";
|
import { ExecFileFn } from "./types";
|
||||||
|
|
||||||
export const properties = {
|
export const properties = {
|
||||||
from: {
|
from: {
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
import { test } from "bun:test";
|
import { test } from "bun:test";
|
||||||
import { convert } from "../../src/converters/assimp.ts";
|
import { convert } from "../../src/converters/assimp";
|
||||||
import { runCommonTests } from "./helpers/commonTests.ts";
|
import { runCommonTests } from "./helpers/commonTests";
|
||||||
|
|
||||||
runCommonTests(convert);
|
runCommonTests(convert);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
import { test } from "bun:test";
|
import { test } from "bun:test";
|
||||||
import { convert } from "../../src/converters/calibre.ts";
|
import { convert } from "../../src/converters/calibre";
|
||||||
import { runCommonTests } from "./helpers/commonTests.ts";
|
import { runCommonTests } from "./helpers/commonTests";
|
||||||
|
|
||||||
runCommonTests(convert);
|
runCommonTests(convert);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,8 +1,8 @@
|
||||||
import type { ExecFileException } from "node:child_process";
|
import type { ExecFileException } from "node:child_process";
|
||||||
import { beforeEach, expect, test } from "bun:test";
|
import { beforeEach, expect, test } from "bun:test";
|
||||||
import { convert } from "../../src/converters/dvisvgm.ts";
|
import { convert } from "../../src/converters/dvisvgm";
|
||||||
import { ExecFileFn } from "../../src/converters/types.ts";
|
import { ExecFileFn } from "../../src/converters/types";
|
||||||
import { runCommonTests } from "./helpers/commonTests.ts";
|
import { runCommonTests } from "./helpers/commonTests";
|
||||||
|
|
||||||
let calls: string[][] = [];
|
let calls: string[][] = [];
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
import { beforeEach, expect, test } from "bun:test";
|
import { beforeEach, expect, test } from "bun:test";
|
||||||
import { convert } from "../../src/converters/ffmpeg.ts";
|
import { convert } from "../../src/converters/ffmpeg";
|
||||||
|
|
||||||
let calls: string[][] = [];
|
let calls: string[][] = [];
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
import { test } from "bun:test";
|
import { test } from "bun:test";
|
||||||
import { convert } from "../../src/converters/graphicsmagick.ts";
|
import { convert } from "../../src/converters/graphicsmagick";
|
||||||
import { runCommonTests } from "./helpers/commonTests.ts";
|
import { runCommonTests } from "./helpers/commonTests";
|
||||||
|
|
||||||
runCommonTests(convert);
|
runCommonTests(convert);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,11 +1,11 @@
|
||||||
import { test } from "bun:test";
|
import { test } from "bun:test";
|
||||||
import { ConvertFnWithExecFile } from "../../../src/converters/types.ts";
|
import { ConvertFnWithExecFile } from "../../../src/converters/types";
|
||||||
import {
|
import {
|
||||||
runConvertFailTest,
|
runConvertFailTest,
|
||||||
runConvertLogsStderror,
|
runConvertLogsStderror,
|
||||||
runConvertLogsStderrorAndStdout,
|
runConvertLogsStderrorAndStdout,
|
||||||
runConvertSuccessTest,
|
runConvertSuccessTest,
|
||||||
} from "./converters.ts";
|
} from "./converters";
|
||||||
|
|
||||||
export function runCommonTests(convert: ConvertFnWithExecFile) {
|
export function runCommonTests(convert: ConvertFnWithExecFile) {
|
||||||
test("convert resolves when execFile succeeds", async () => {
|
test("convert resolves when execFile succeeds", async () => {
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
import type { ExecFileException } from "node:child_process";
|
import type { ExecFileException } from "node:child_process";
|
||||||
import { expect } from "bun:test";
|
import { expect } from "bun:test";
|
||||||
import { ConvertFnWithExecFile, ExecFileFn } from "../../../src/converters/types.ts";
|
import { ConvertFnWithExecFile, ExecFileFn } from "../../../src/converters/types";
|
||||||
|
|
||||||
export async function runConvertSuccessTest(convertFn: ConvertFnWithExecFile) {
|
export async function runConvertSuccessTest(convertFn: ConvertFnWithExecFile) {
|
||||||
const originalConsoleLog = console.log;
|
const originalConsoleLog = console.log;
|
||||||
|
|
|
||||||
|
|
@ -1,8 +1,8 @@
|
||||||
import type { ExecFileException } from "node:child_process";
|
import type { ExecFileException } from "node:child_process";
|
||||||
import { beforeEach, expect, test } from "bun:test";
|
import { beforeEach, expect, test } from "bun:test";
|
||||||
import { convert } from "../../src/converters/imagemagick.ts";
|
import { convert } from "../../src/converters/imagemagick";
|
||||||
import { ExecFileFn } from "../../src/converters/types.ts";
|
import { ExecFileFn } from "../../src/converters/types";
|
||||||
import { runCommonTests } from "./helpers/commonTests.ts";
|
import { runCommonTests } from "./helpers/commonTests";
|
||||||
|
|
||||||
let calls: string[][] = [];
|
let calls: string[][] = [];
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
import { test } from "bun:test";
|
import { test } from "bun:test";
|
||||||
import { convert } from "../../src/converters/inkscape.ts";
|
import { convert } from "../../src/converters/inkscape";
|
||||||
import { runCommonTests } from "./helpers/commonTests.ts";
|
import { runCommonTests } from "./helpers/commonTests";
|
||||||
|
|
||||||
runCommonTests(convert);
|
runCommonTests(convert);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
import { test } from "bun:test";
|
import { test } from "bun:test";
|
||||||
import { convert } from "../../src/converters/libheif.ts";
|
import { convert } from "../../src/converters/libheif";
|
||||||
import { runCommonTests } from "./helpers/commonTests.ts";
|
import { runCommonTests } from "./helpers/commonTests";
|
||||||
|
|
||||||
runCommonTests(convert);
|
runCommonTests(convert);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,8 +1,8 @@
|
||||||
import type { ExecFileException } from "node:child_process";
|
import type { ExecFileException } from "node:child_process";
|
||||||
import { beforeEach, expect, test } from "bun:test";
|
import { beforeEach, expect, test } from "bun:test";
|
||||||
import { convert } from "../../src/converters/libjxl.ts";
|
import { convert } from "../../src/converters/libjxl";
|
||||||
import { ExecFileFn } from "../../src/converters/types.ts";
|
import { ExecFileFn } from "../../src/converters/types";
|
||||||
import { runCommonTests } from "./helpers/commonTests.ts";
|
import { runCommonTests } from "./helpers/commonTests";
|
||||||
|
|
||||||
let command: string = "";
|
let command: string = "";
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
import type { ExecFileException } from "node:child_process";
|
import type { ExecFileException } from "node:child_process";
|
||||||
import { expect, test } from "bun:test";
|
import { expect, test } from "bun:test";
|
||||||
import { convert } from "../../src/converters/msgconvert.ts";
|
import { convert } from "../../src/converters/msgconvert";
|
||||||
import { ExecFileFn } from "../../src/converters/types.ts";
|
import { ExecFileFn } from "../../src/converters/types";
|
||||||
|
|
||||||
test("convert rejects conversion if input filetype is not msg and output type is not eml", async () => {
|
test("convert rejects conversion if input filetype is not msg and output type is not eml", async () => {
|
||||||
const mockExecFile: ExecFileFn = (
|
const mockExecFile: ExecFileFn = (
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
import { test } from "bun:test";
|
import { test } from "bun:test";
|
||||||
import { convert } from "../../src/converters/potrace.ts";
|
import { convert } from "../../src/converters/potrace";
|
||||||
import { runCommonTests } from "./helpers/commonTests.ts";
|
import { runCommonTests } from "./helpers/commonTests";
|
||||||
|
|
||||||
runCommonTests(convert);
|
runCommonTests(convert);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
import { test } from "bun:test";
|
import { test } from "bun:test";
|
||||||
import { convert } from "../../src/converters/resvg.ts";
|
import { convert } from "../../src/converters/resvg";
|
||||||
import { runCommonTests } from "./helpers/commonTests.ts";
|
import { runCommonTests } from "./helpers/commonTests";
|
||||||
|
|
||||||
runCommonTests(convert);
|
runCommonTests(convert);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,8 +1,8 @@
|
||||||
import type { ExecFileException } from "node:child_process";
|
import type { ExecFileException } from "node:child_process";
|
||||||
import { beforeEach, expect, test } from "bun:test";
|
import { beforeEach, expect, test } from "bun:test";
|
||||||
import { ExecFileFn } from "../../src/converters/types.ts";
|
import { ExecFileFn } from "../../src/converters/types";
|
||||||
import { convert } from "../../src/converters/vips.ts";
|
import { convert } from "../../src/converters/vips";
|
||||||
import { runCommonTests } from "./helpers/commonTests.ts";
|
import { runCommonTests } from "./helpers/commonTests";
|
||||||
|
|
||||||
let calls: string[][] = [];
|
let calls: string[][] = [];
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
import { test } from "bun:test";
|
import { test } from "bun:test";
|
||||||
import { convert } from "../../src/converters/xelatex.ts";
|
import { convert } from "../../src/converters/xelatex";
|
||||||
import { runCommonTests } from "./helpers/commonTests.ts";
|
import { runCommonTests } from "./helpers/commonTests";
|
||||||
|
|
||||||
runCommonTests(convert);
|
runCommonTests(convert);
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue