Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/dileep17/petstoreapi
A sample project to spike TestServer for Integration Test .Net core WebAPI
https://github.com/dileep17/petstoreapi
Last synced: 14 days ago
JSON representation
A sample project to spike TestServer for Integration Test .Net core WebAPI
- Host: GitHub
- URL: https://github.com/dileep17/petstoreapi
- Owner: Dileep17
- Created: 2018-06-11T06:10:04.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2018-06-11T17:09:45.000Z (over 6 years ago)
- Last Synced: 2024-11-05T10:59:51.610Z (2 months ago)
- Language: C#
- Size: 24.4 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# PetStoreAPI
A sample project to spike TestServer for Integration Test .Net core WebAPI.a. Tests in TestsWithDB folder use same config as specified for PetStoreAPI project
b. Tests in InMemoryTest folder in memory DB
c. Tests in MockTests folder use same config as specified for PetStoreAPI project and uses Stubbery library to mock external service calls
Steps to run tests
1. Install Postgres DB and create "PetStore" Database
2. Create Tables as belowCREATE TABLE public."Pets"
(
"Id" integer NOT NULL DEFAULT nextval('"Pets_id_seq"'::regclass),
"Name" character varying,
"Family" character varying,
CONSTRAINT "Pets_pkey" PRIMARY KEY ("Id")
)
WITH (
OIDS=FALSE
);CREATE TABLE public."Owners"
(
"Id" integer NOT NULL DEFAULT nextval('"Owners_id_seq"'::regclass),
"Name" character varying,
CONSTRAINT "Owners_pkey" PRIMARY KEY ("Id")
)
WITH (
OIDS=FALSE
);
3. Build and Run Nunit Tests in IntegrationTests project