FreeDATA/gui/tests/api.test.js
2023-11-20 14:24:45 +01:00

8 lines
254 B
JavaScript

import { expect, test } from "vitest";
import { buildURL } from "../src/js/api";
test("builds URLs correctly"),
() => {
const params = { host: "127.0.0.1", port: 123 };
expect(buildURL(params, "/config")).toBe("http://127.0.0.1/config");
};