ui_migration chore(suggestions) Added whole state check at settings.spec.js and writting issues based on comments
This commit is contained in:
parent
2fad2b5298
commit
f28c7a5699
2 changed files with 18 additions and 3 deletions
|
|
@ -25,10 +25,28 @@ describe("Settings Store", () => {
|
|||
|
||||
it("initializes with correct default state", () => {
|
||||
const store = useSettingsStore();
|
||||
// Checks whole state items
|
||||
expect(store.ready).toBe(false);
|
||||
expect(store.waiting).toBe(false);
|
||||
expect(store.appTheme).toBe("system");
|
||||
expect(store.activeStreams).toEqual({});
|
||||
expect(store.error).toBe("");
|
||||
expect(store.trackWindow).toBe(true);
|
||||
expect(store.microscopeHostname).toBe("");
|
||||
expect(store.disableStream).toBe(false);
|
||||
expect(store.overrideOrigin).toBe("http://microscope.local:5000/api/v3");
|
||||
|
||||
expect(store.navigationStepSize).toEqual({
|
||||
x: 200,
|
||||
y: 200,
|
||||
z: 50,
|
||||
});
|
||||
|
||||
expect(store.navigationInvert).toEqual({
|
||||
x: false,
|
||||
y: false,
|
||||
z: false,
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
|
|
|
|||
|
|
@ -8,9 +8,6 @@ vi.mock("axios");
|
|||
|
||||
describe("WoT Store", () => {
|
||||
// A reusable dummy Thing Description (TD)
|
||||
// This will be reworked by using the HAR fixtures or the fixtures/common_definitions.js
|
||||
// This test uses arbitrary values for simplicity but this could add confusion
|
||||
// How-to-test documentation would require a glossary of defined mock values
|
||||
const mockTD = {
|
||||
base: "http://microscope.local/api/v3/",
|
||||
properties: {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue