Skip to content

menvic/simple-job-queue

Repository files navigation

docs to test api with use docker (laravel sail)

1. add config file

rename .env.example to .env

2. composer and npm install

composer i
npm i

3. run/start docker

./vendor/bin/sail up -d

4. make migration (not required - should have with docker)

./vendor/bin/sail artisan migrate:fresh

5. url to test API with POST request

http://localhost/api/submit

JSON payload:

{
    "name": "John Doe",
    "email": "john.doe@example.com",
    "message": "This is a test message."
}

6. Unit tests

6.1 make DB migration

./vendor/bin/sail artisan migrate:fresh --env=testing

6.2 run test

./vendor/bin/sail artisan test --filter SubmissionControllerTest

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published