fix navigation-to-extension-specific-preferences.test.tsx

Signed-off-by: Sebastian Malton <sebastian@malton.name>
This commit is contained in:
Sebastian Malton committed 2022-05-04 08:47:20 -04:00
1 parent 38192d3360
commit d3723af27a
2 files changed
+20 -31

No files matched your search

@@ -105,7 +105,7 @@ exports[`preferences - navigation to extension specific preferences given in pre
class="SubTitle"
>
Theme
</div>
<div
class="Select theme-lens css-b62m3t-container"
@@ -190,7 +190,7 @@ exports[`preferences - navigation to extension specific preferences given in pre
class="SubTitle"
>
Extension Install Registry
</div>
<div
class="Select theme-lens css-b62m3t-container"
@@ -270,16 +270,11 @@ exports[`preferences - navigation to extension specific preferences given in pre
class="mt-4 mb-5 leading-relaxed"
>
This setting is to change the registry URL for installing extensions by name.
If you are unable to access the default registry (
https://registry.npmjs.org
)
you can change it in your
If you are unable to access the default registry (https://registry.npmjs.org) you can change it in your
<b>
.npmrc
</b>
 file or in the input below.
file or in the input below.
</p>
<div
class="Input theme round black disabled invalid"
@@ -309,7 +304,7 @@ exports[`preferences - navigation to extension specific preferences given in pre
class="SubTitle"
>
Start-up
</div>
<label
class="Switch"
@@ -330,7 +325,7 @@ exports[`preferences - navigation to extension specific preferences given in pre
class="SubTitle"
>
Update Channel
</div>
<div
class="Select theme-lens css-b62m3t-container"
@@ -415,7 +410,7 @@ exports[`preferences - navigation to extension specific preferences given in pre
class="SubTitle"
>
Locale Timezone
</div>
<div
class="Select theme-lens css-b62m3t-container"
@@ -650,7 +645,7 @@ exports[`preferences - navigation to extension specific preferences given in pre
class="SubTitle"
>
Theme
</div>
<div
class="Select theme-lens css-b62m3t-container"
@@ -735,7 +730,7 @@ exports[`preferences - navigation to extension specific preferences given in pre
class="SubTitle"
>
Extension Install Registry
</div>
<div
class="Select theme-lens css-b62m3t-container"
@@ -815,16 +810,11 @@ exports[`preferences - navigation to extension specific preferences given in pre
class="mt-4 mb-5 leading-relaxed"
>
This setting is to change the registry URL for installing extensions by name.
If you are unable to access the default registry (
https://registry.npmjs.org
)
you can change it in your
If you are unable to access the default registry (https://registry.npmjs.org) you can change it in your
<b>
.npmrc
</b>
 file or in the input below.
file or in the input below.
</p>
<div
class="Input theme round black disabled invalid"
@@ -854,7 +844,7 @@ exports[`preferences - navigation to extension specific preferences given in pre
class="SubTitle"
>
Start-up
</div>
<label
class="Switch"
@@ -875,7 +865,7 @@ exports[`preferences - navigation to extension specific preferences given in pre
class="SubTitle"
>
Update Channel
</div>
<div
class="Select theme-lens css-b62m3t-container"
@@ -960,7 +950,7 @@ exports[`preferences - navigation to extension specific preferences given in pre
class="SubTitle"
>
Locale Timezone
</div>
<div
class="Select theme-lens css-b62m3t-container"
@@ -1195,7 +1185,7 @@ exports[`preferences - navigation to extension specific preferences given in pre
class="SubTitle"
>
Some preference item
</div>
<div
data-testid="some-preference-item-input"
@@ -7,11 +7,10 @@ import type { ApplicationBuilder } from "../../renderer/components/test-utils/ge
import { getApplicationBuilder } from "../../renderer/components/test-utils/get-application-builder";
import userStoreInjectable from "../../common/user-store/user-store.injectable";
import type { UserStore } from "../../common/user-store";
import themeStoreInjectable from "../../renderer/themes/store.injectable";
import type { ThemeStore } from "../../renderer/themes/store";
import { LensRendererExtension } from "../../extensions/lens-renderer-extension";
import React from "react";
import { getRendererExtensionFake } from "../../renderer/components/test-utils/get-renderer-extension-fake";
import ipcRendererInjectable from "../../renderer/app-paths/get-value-from-registered-channel/ipc-renderer/ipc-renderer.injectable";
describe("preferences - navigation to extension specific preferences", () => {
let applicationBuilder: ApplicationBuilder;
@@ -25,10 +24,10 @@ describe("preferences - navigation to extension specific preferences", () => {
} as unknown as UserStore;
rendererDi.override(userStoreInjectable, () => userStoreStub);
const themeStoreStub = { themeOptions: [] } as unknown as ThemeStore;
rendererDi.override(themeStoreInjectable, () => themeStoreStub);
rendererDi.override(ipcRendererInjectable, () => ({
on: jest.fn(),
invoke: jest.fn(), // TODO: replace with proper mocking via the IPC bridge
} as never));
});
});