Files
lucia-frontend/tests/components/Loading.test.js
2026-03-08 12:11:57 +08:00

22 lines
637 B
JavaScript

// The Lucia project.
// Copyright 2026-2026 DSP, inc. All rights reserved.
// Authors:
// imacat.yang@dsp.im (imacat), 2026/03/05
import { describe, it, expect } from "vitest";
import { mount } from "@vue/test-utils";
import Loading from "@/components/Loading.vue";
describe("Loading", () => {
it("renders a loader element", () => {
const wrapper = mount(Loading);
expect(wrapper.find(".loader").exists()).toBe(true);
});
it("has full-screen overlay classes", () => {
const wrapper = mount(Loading);
expect(wrapper.classes()).toContain("fixed");
expect(wrapper.classes()).toContain("inset-0");
});
});