diff --git a/src/rageshake/submit-rageshake.ts b/src/rageshake/submit-rageshake.ts index 0717ccd56a..2815b50a0c 100644 --- a/src/rageshake/submit-rageshake.ts +++ b/src/rageshake/submit-rageshake.ts @@ -232,10 +232,6 @@ async function collectRecoveryInfo(client: MatrixClient, cryptoApi: CryptoApi, b * Collects labels to add to the report. */ export function collectLabels(client: MatrixClient | null, opts: IOpts, body: FormData): void { - if (client?.getCrypto()?.getVersion()?.startsWith(`Rust SDK`)) { - body.append("label", "A-Element-R"); - } - if (opts.labels) { for (const label of opts.labels) { body.append("label", label); diff --git a/test/unit-tests/submit-rageshake-test.ts b/test/unit-tests/submit-rageshake-test.ts index f31102e3ba..c48d79b772 100644 --- a/test/unit-tests/submit-rageshake-test.ts +++ b/test/unit-tests/submit-rageshake-test.ts @@ -25,8 +25,6 @@ import { type FeatureSettingKey, type SettingKey } from "../../src/settings/Sett import { SettingLevel } from "../../src/settings/SettingLevel.ts"; describe("Rageshakes", () => { - const RUST_CRYPTO_VERSION = "Rust SDK 0.7.0 (691ec63), Vodozemac 0.5.0"; - const OLM_CRYPTO_VERSION = "Olm 3.2.15"; let mockClient: Mocked; const mockHttpAPI: MatrixHttpApi = new MatrixHttpApi( new TypedEventEmitter(), @@ -536,52 +534,6 @@ describe("Rageshakes", () => { } }); - describe("A-Element-R label", () => { - test("should add A-Element-R label if rust crypto", async () => { - mocked(mockClient.getCrypto()!.getVersion).mockReturnValue(RUST_CRYPTO_VERSION); - - const formData = await collectBugReport(); - const labelNames = formData.getAll("label"); - expect(labelNames).toContain("A-Element-R"); - }); - - test("should add A-Element-R label if rust crypto and new version", async () => { - mocked(mockClient.getCrypto()!.getVersion).mockReturnValue("Rust SDK 0.9.3 (909d09fd), Vodozemac 0.8.1"); - - const formData = await collectBugReport(); - const labelNames = formData.getAll("label"); - expect(labelNames).toContain("A-Element-R"); - }); - - test("should not add A-Element-R label if not rust crypto", async () => { - mocked(mockClient.getCrypto()!.getVersion).mockReturnValue(OLM_CRYPTO_VERSION); - - const formData = await collectBugReport(); - const labelNames = formData.getAll("label"); - expect(labelNames).not.toContain("A-Element-R"); - }); - - test("should add A-Element-R label to the set of requested labels", async () => { - mocked(mockClient.getCrypto()!.getVersion).mockReturnValue(RUST_CRYPTO_VERSION); - - const formData = await collectBugReport({ - labels: ["Z-UISI", "Foo"], - }); - const labelNames = formData.getAll("label"); - expect(labelNames).toContain("A-Element-R"); - expect(labelNames).toContain("Z-UISI"); - expect(labelNames).toContain("Foo"); - }); - - test("should not panic if there is no crypto", async () => { - mocked(mockClient.getCrypto).mockReturnValue(undefined); - - const formData = await collectBugReport(); - const labelNames = formData.getAll("label"); - expect(labelNames).not.toContain("A-Element-R"); - }); - }); - it("should notify progress", () => { const progressCallback = jest.fn();