dotnet_assessment

Steps to Run

$git clone https://github.com/techiehkr/dotnet_assessment.git
$cd dotnet_assessment
$cd BookApi
$dotnet run

API links:-

Book

GET

/api/Book/publisher-author-title

GET

/api/Book/author-title

GET

/api/Book/total-price

POST

/api/Book/bulk-insert

GET

/api/Book/SP-publisher-author-title

GET

/api/Book/SP-author-title

BookControllerDto

GET

/api/BookControllerDto/publisher-author-title

GET

/api/BookControllerDto/author-title

GET

/api/BookControllerDto/total-price

POST

/api/BookControllerDto/bulk-insert

alt text

Steps to Run Tests

$cd dotnet_assessment
$cd BookApi.Tests
$dotnet test

Output

Determining projects to restore... <br />
  Restored /home/user/Desktop/dotnet_assessment/BookApi.Tests/BookApi.Tests.csproj (in 401 ms). <br />
  1 of 2 projects are up-to-date for restore. <br />
  BookApi -> /home/user/Desktop/dotnet_assessment/BookApi/bin/Debug/net8.0/BookApi.dll <br />
  BookApi.Tests -> /home/user/Desktop/dotnet_assessment/BookApi.Tests/bin/Debug/net8.0/BookApi.Tests.dll <br />
Test run for /home/user/Desktop/dotnet_assessment/BookApi.Tests/bin/Debug/net8.0/BookApi.Tests.dll (.NETCoreApp,Version=v8.0) <br />
Microsoft (R) Test Execution Command Line Tool Version 17.8.0 (x64) <br />
Copyright (c) Microsoft Corporation.  All rights reserved. <br />

Starting test execution, please wait... <br />
A total of 1 test files matched the specified pattern. <br />

Passed!  - Failed:     0, Passed:     5, Skipped:     0, Total:     5, Duration: 95 ms - BookApi.Tests.dll (net8.0) <br />

Dotnet version 8

Used Dependencies

"AutoMapper": "12.0.0",
"AutoMapper.Extensions.Microsoft.DependencyInjection": "12.0.0",
"EFCore.BulkExtensions": "8.0.4",
"Microsoft.AspNetCore.OpenApi": "8.0.5",
"Microsoft.EntityFrameworkCore.Design": "8.0.6",
"Microsoft.EntityFrameworkCore.Sqlite": "8.0.6",
"Microsoft.EntityFrameworkCore.Tools": "8.0.6",
"Swashbuckle.AspNetCore": "6.6.2"