mirror of
https://github.com/webadderallorg/Recordly.git
synced 2026-09-24 14:55:37 +00:00
27 lines
863 B
TypeScript
27 lines
863 B
TypeScript
import { describe, expect, it } from "vitest";
|
|
import { EXPERIMENTAL_UPDATE_DESCRIPTION, getUpdateChannelConfiguration } from "./updateChannel";
|
|
|
|
describe("getUpdateChannelConfiguration", () => {
|
|
it("keeps regular clients on stable metadata", () => {
|
|
expect(getUpdateChannelConfiguration(false)).toEqual({
|
|
channel: "latest",
|
|
allowPrerelease: false,
|
|
allowDowngrade: false,
|
|
});
|
|
});
|
|
|
|
it("uses beta metadata only after the client opts in", () => {
|
|
expect(getUpdateChannelConfiguration(true)).toEqual({
|
|
channel: "beta",
|
|
allowPrerelease: true,
|
|
allowDowngrade: false,
|
|
});
|
|
});
|
|
|
|
it("uses the approved experimental update description", () => {
|
|
expect(EXPERIMENTAL_UPDATE_DESCRIPTION).toBe(
|
|
"You've opted into experimental updates so you have the choice to test the latest update of Recordly before it's widely available.",
|
|
);
|
|
});
|
|
});
|