From dce8873b63fda753210871e6c35637daa881b04d Mon Sep 17 00:00:00 2001 From: Vargha Csongor Date: Sat, 19 Apr 2025 16:44:51 +0200 Subject: [PATCH] add bruno testing --- apps/db-adapter/example-payloads/bruno.json | 9 +++++ .../create_person_by_google_id.bru | 31 +++++++++++++++++ ...te_person_by_google_id_and_invite_code.bru | 34 +++++++++++++++++++ .../get_person_by_google_id.bru | 11 ++++++ 4 files changed, 85 insertions(+) create mode 100644 apps/db-adapter/example-payloads/bruno.json create mode 100644 apps/db-adapter/example-payloads/create_person_by_google_id.bru create mode 100644 apps/db-adapter/example-payloads/create_person_by_google_id_and_invite_code.bru create mode 100644 apps/db-adapter/example-payloads/get_person_by_google_id.bru diff --git a/apps/db-adapter/example-payloads/bruno.json b/apps/db-adapter/example-payloads/bruno.json new file mode 100644 index 0000000..e072d64 --- /dev/null +++ b/apps/db-adapter/example-payloads/bruno.json @@ -0,0 +1,9 @@ +{ + "version": "1", + "name": "example-payloads", + "type": "collection", + "ignore": [ + "node_modules", + ".git" + ] +} \ No newline at end of file diff --git a/apps/db-adapter/example-payloads/create_person_by_google_id.bru b/apps/db-adapter/example-payloads/create_person_by_google_id.bru new file mode 100644 index 0000000..0d18b47 --- /dev/null +++ b/apps/db-adapter/example-payloads/create_person_by_google_id.bru @@ -0,0 +1,31 @@ +meta { + name: create_person_by_google_id + type: http + seq: 1 +} + +post { + url: http://localhost:8080/person/google/{{google_id}} + body: json + auth: inherit +} + +headers { + Content-Type: application/json +} + +body:json { + { + "first_name": "Alice", + "last_name": "Wonderland", + "born": "1990-06-01", + "limit": 100, + "mothers_first_name": "Mary", + "mothers_last_name": "Smith", + "email": "alice@example.com" + } +} + +vars:pre-request { + google_id: alice123 +} diff --git a/apps/db-adapter/example-payloads/create_person_by_google_id_and_invite_code.bru b/apps/db-adapter/example-payloads/create_person_by_google_id_and_invite_code.bru new file mode 100644 index 0000000..3476e5a --- /dev/null +++ b/apps/db-adapter/example-payloads/create_person_by_google_id_and_invite_code.bru @@ -0,0 +1,34 @@ +meta { + name: create_person_by_google_id_and_invite_code + type: http + seq: 4 +} + +patch { + url: http://localhost:8080/person/google/{{google_id}} + body: json + auth: inherit +} + +headers { + Content-Type: application/json +} + +body:json { + { + "invite_code": "INV123456", + "person": { + "first_name": "Bob", + "last_name": "Builder", + "born": "1985-11-25", + "limit": 200, + "mothers_first_name": "Linda", + "mothers_last_name": "Builder", + "email": "bob@example.com" + } + } +} + +vars:pre-request { + google_id: bob456 +} diff --git a/apps/db-adapter/example-payloads/get_person_by_google_id.bru b/apps/db-adapter/example-payloads/get_person_by_google_id.bru new file mode 100644 index 0000000..320a262 --- /dev/null +++ b/apps/db-adapter/example-payloads/get_person_by_google_id.bru @@ -0,0 +1,11 @@ +meta { + name: get_person_by_google_id + type: http + seq: 2 +} + +get { + url: http://localhost:8080/person/google/{{google_id}} + body: none + auth: inherit +}