From 74a634c642f74c3ec165d77f4b5dcb9247fdae53 Mon Sep 17 00:00:00 2001 From: Henry-Hiles Date: Fri, 1 Aug 2025 16:33:01 -0400 Subject: [PATCH] Add testing --- .gitignore | 2 +- .vscode/launch.json | 24 +++++++++++++++--------- JUSTFILE | 2 +- 3 files changed, 17 insertions(+), 11 deletions(-) diff --git a/.gitignore b/.gitignore index 3bc06ec..6500c0e 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,3 @@ .dart_tool/ .direnv -secret \ No newline at end of file +secrets/ \ No newline at end of file diff --git a/.vscode/launch.json b/.vscode/launch.json index f4d08eb..64e643b 100644 --- a/.vscode/launch.json +++ b/.vscode/launch.json @@ -5,19 +5,25 @@ "version": "0.2.0", "configurations": [ { - "name": "matrix-oauth2oidc", + "name": "nexusbot", "program": "bin/nexusbot.dart", "args": [ + "--socket", + "./socket", "--homeserver", "https://matrix.federated.nexus", - "--jwtSecretFile", - "secret", - "--issuer", - "http://localhost:8080", - "--authorizeEndpoint", - "http://localhost:4321/login", - "--serviceDomain", - "federated.nexus" + "--name", + "nexusbot", + "--inviteTo", + "#community:federated.nexus", + "--adminRoom", + "#admins:federated.nexus", + "--successUri", + "https://federated.nexus/success", + "--botPasswordFile", + "secrets/botPassword.txt", + "--smtpPasswordFile", + "secrets/smtpPassword.txt" ], "request": "launch", "type": "dart" diff --git a/JUSTFILE b/JUSTFILE index 0a86649..5fa18e3 100644 --- a/JUSTFILE +++ b/JUSTFILE @@ -5,4 +5,4 @@ build: dart run build_runner build test: - oauth2c http://localhost:8080 --client-id yourclientid --scopes openid --grant-type authorization_code --auth-method none --response-mode query \ No newline at end of file + curl --unix-socket ./socket http:/root -X POST -d '{"email": "foo", "username": "bar"}' \ No newline at end of file