self review

This commit is contained in:
Elio Bischof
2023-06-08 07:42:35 +02:00
parent 9f8a24ad7c
commit a8a3001db5
4 changed files with 8 additions and 10 deletions

View File

@@ -50,11 +50,11 @@ You can execute the following commands in the following directories:
- The projects root directory: all tests in the project are executed - The projects root directory: all tests in the project are executed
```sh ```sh
# Run unit and integration tests once # Run all once
pnpm run test -- --passWithNoTests pnpm test
# Rerun unit and integration tests on file changes # Rerun tests on file changes
pnpm run test:watch -- --passWithNoTests pnpm test:watch
``` ```
### Developing Against Your Local ZITADEL Instance ### Developing Against Your Local ZITADEL Instance

View File

@@ -8,7 +8,6 @@ import React, {
InputHTMLAttributes, InputHTMLAttributes,
ReactNode, ReactNode,
} from "react"; } from "react";
import { v4 as uuidv4 } from "uuid";
export type TextInputProps = DetailedHTMLProps< export type TextInputProps = DetailedHTMLProps<
InputHTMLAttributes<HTMLInputElement>, InputHTMLAttributes<HTMLInputElement>,
@@ -55,7 +54,6 @@ export const TextInput = forwardRef<HTMLInputElement, TextInputProps>(
}, },
ref ref
) => { ) => {
const id = uuidv4();
return ( return (
<label className="flex flex-col text-12px text-input-light-label dark:text-input-dark-label"> <label className="flex flex-col text-12px text-input-light-label dark:text-input-dark-label">
<span <span

View File

@@ -27,7 +27,7 @@ describe('authMiddleware', () => {
it(name, async () => { it(name, async () => {
const mockNext = jest.fn().mockImplementation(async function*() { }); const mockNext = jest.fn().mockImplementation(async function*() { });
const mockRequest = {}; // Ersetze dies mit einem geeigneten Mock Request-Objekt const mockRequest = {};
const mockMethodDescriptor: MethodDescriptor = { const mockMethodDescriptor: MethodDescriptor = {
options: {idempotencyLevel: undefined}, options: {idempotencyLevel: undefined},
@@ -38,7 +38,7 @@ describe('authMiddleware', () => {
const mockCall: ClientMiddlewareCall<unknown, unknown> = { const mockCall: ClientMiddlewareCall<unknown, unknown> = {
method: mockMethodDescriptor, method: mockMethodDescriptor,
requestStream: false, // Setze diese Werte entsprechend deiner Testbedingungen requestStream: false,
responseStream: false, responseStream: false,
request: mockRequest, request: mockRequest,
next: mockNext, next: mockNext,

View File

@@ -27,7 +27,7 @@ describe('authMiddleware', () => {
it(name, async () => { it(name, async () => {
const mockNext = jest.fn().mockImplementation(async function*() { }); const mockNext = jest.fn().mockImplementation(async function*() { });
const mockRequest = {}; // Ersetze dies mit einem geeigneten Mock Request-Objekt const mockRequest = {};
const mockMethodDescriptor: MethodDescriptor = { const mockMethodDescriptor: MethodDescriptor = {
options: {idempotencyLevel: undefined}, options: {idempotencyLevel: undefined},
@@ -38,7 +38,7 @@ describe('authMiddleware', () => {
const mockCall: ClientMiddlewareCall<unknown, unknown> = { const mockCall: ClientMiddlewareCall<unknown, unknown> = {
method: mockMethodDescriptor, method: mockMethodDescriptor,
requestStream: false, // Setze diese Werte entsprechend deiner Testbedingungen requestStream: false,
responseStream: false, responseStream: false,
request: mockRequest, request: mockRequest,
next: mockNext, next: mockNext,