Skip to content

Latest commit

 

History

17 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

image

Prereq

Docker og Rust

Corp Data API

Start postgreSQL database

Lav environment variabler, brug ".prod.env" som skabelon

Logging:

$env:RUST_LOG="info,corp_data_api=debug,sqlx=info";

Kør API

cargo run

Opret et office (Powershell)

Invoke-RestMethod -Uri http://127.0.0.1:3000/offices `
  -Method Post `
  -ContentType "application/json" `
  -Body '{
    "name": "Aalborg",
    "max_occupancy": 3
  }'

Tests

Indeholder grundlæggende tests alle lag:

Lav .env.test som indeholder:

POSTGRES_USER=test_user
POSTGRES_PASSWORD=test_password
POSTGRES_DB=test
POSTGRES_HOST=localhost
POSTGRES_PORT=5432
cargo test

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages