Skip to content

Commit

Permalink
updated tests
Browse files Browse the repository at this point in the history
  • Loading branch information
sinamics committed Jul 19, 2023
1 parent 536e11f commit f16c7f3
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
5 changes: 3 additions & 2 deletions src/__tests__/pages/network/[id].test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ describe("NetworkById component", () => {
expect(screen.getByText(/Network ID:/i)).toBeInTheDocument();
expect(screen.getByText(/Network Name:/i)).toBeInTheDocument();
expect(screen.getByText(/Test Network/i)).toBeInTheDocument();
expect(screen.getByText("Network Auth")).toBeInTheDocument();
expect(screen.getByText(/Network Auth/i)).toBeInTheDocument();
});

test("renders Network Settings divider", () => {
Expand All @@ -134,7 +134,8 @@ describe("NetworkById component", () => {

test("renders Network Members divider", () => {
render(<NetworkById />);
expect(screen.getByText(/Network Members/i)).toBeInTheDocument();
const matches = screen.getAllByText(/Network Members/i);
expect(matches.length).toBe(2);
});

test("renders Network Start, Network End, and Network Cidr labels", () => {
Expand Down
4 changes: 2 additions & 2 deletions src/components/modules/networkHelp.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -130,8 +130,8 @@ const NetworkHelpText: React.FC = () => (
</p>
<p className="text-gray-400">
This must be enabled on each client with the allowDNS option.
There is a checkbox in the UI in each network's details, near
the Allow Managed checkbox.
There is a checkbox in the UI in each networks details, near the
Allow Managed checkbox.
</p>
</section>
</section>
Expand Down
1 change: 0 additions & 1 deletion src/server/api/networkService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,6 @@ export async function handleAutoAssignIP(
if (!Array.isArray(routes)) {
return;
}
console.log(routes);
// else update network with new ipAssignmentPools
const pool = IPv4gen(routes["target"]);
ztControllerUpdates.ipAssignmentPools =
Expand Down

0 comments on commit f16c7f3

Please sign in to comment.