CEC-2977 Filter portal access based on auth provider (#231)

* fix/fleet-vehicles-search

* fix/fleet-name-update

* Update hasRole logic, create RoleWrap component

* Add MAGNA and MAGNAGROUP env vars

* Add Permissions

Co-authored-by: jwu-fisker <jwu@fiskerinc.com>
This commit is contained in:
arpanetus
2022-11-09 06:46:33 +06:00
committed by GitHub
parent 94950d583e
commit f2f046968e
76 changed files with 1321 additions and 917 deletions

View File

@@ -10,7 +10,7 @@ import { render, waitFor } from "@testing-library/react";
import { StatusProvider } from "../../Contexts/StatusContext";
import { UserProvider, setToken } from "../../Contexts/UserContext";
import { TEST_AUTH_OBJECT } from "../../../utils/testing";
import { TEST_AUTH_OBJECT_FISKER } from "../../../utils/testing";
import DigitalTwinTab from "./DigitalTwinTab";
import addSnapshotSerializer from "../../../utils/snapshot";
@@ -34,7 +34,7 @@ describe("DigitalTwinTab", () => {
});
it("Render", async () => {
setToken(TEST_AUTH_OBJECT);
setToken(TEST_AUTH_OBJECT_FISKER);
const container = await renderDetailsTab();
expect(container).toMatchSnapshot();
});