Skip to content

Commit

Permalink
ucs-2 (#6)
Browse files Browse the repository at this point in the history
* ucs-2 + refactoring + fix for url-grouping

* add check for output directory

* remove todo-comments

* add generated types

* remove log
  • Loading branch information
clauyan authored Oct 14, 2024
1 parent b9b73e9 commit 892fc8e
Show file tree
Hide file tree
Showing 19 changed files with 5,796 additions and 89 deletions.
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -129,4 +129,6 @@ dist
.yarn/install-state.gz
.pnp.*

loadtest/data/users.json
loadtest/data/users.json
loadtest/api-client/generated/
output/
24 changes: 19 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,24 @@

Load and performance tests for the schulportal

## How to run
##

### Setup

You will need a working installation of k6. ([How to install k6](https://grafana.com/docs/k6/latest/set-up/install-k6/)).

You have to provide `loadtest/data/users.json` with usernames, passwords and role for the tests to work. An example is provided in `loadtest/data/`.

To create type-definitions for the API run:

```sh
npm run generate-client # to generate new type-definitions for the api
```

This uses `loadtest\api-client\openapispec.json`. You can obtain the file from the `schulportal-client` or a running instance of `dbildungs-iam-server`. Sadly the generated client itself is not usable here, but the types/models are.

### How to run

Tests are categorized as

```
Expand All @@ -26,12 +40,12 @@ And you can selectively run usecases by providing a regex for the filename:
./run.sh "https://example.env/" stress login
```

### Configuration

You have to provide `loadtest/data/users.json` with usernames, passwords and role for the tests to work. An example is provided in `loadtest/data/`.

## Development

```sh
npm run check # to format, lint, typecheck the code
```

```sh
npm run generate-client # to generate new type-definitions for the api
```
Loading

0 comments on commit 892fc8e

Please sign in to comment.