Skip to content

About

Python FastAPI project implementing REST API using Test Driven Development (TDD) with pytest.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

1 Commit

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Incubyte Salary Management Kata

Overview

This project is a Python FastAPI application that provides:

  • Employee CRUD operations
  • Salary calculation endpoint
  • Salary metrics by country
  • Salary metrics by job title

All employee records are stored in a SQLite database.

Tech Stack

  • Python 3.13
  • FastAPI
  • SQLAlchemy
  • SQLite
  • Pytest

Features

Employee CRUD

  • Create employee
  • List employees
  • Get employee by ID
  • Update employee
  • Delete employee

Salary Calculation

Given an employee ID, the API calculates deductions and net salary based on country:

  • India: 10% TDS
  • United States: 12% TDS
  • All other countries: no deductions

Salary Metrics

  • Minimum, maximum, and average salary for a given country
  • Average salary for a given job title

Project Structure

app/
  main.py
  database.py
  models.py
  schemas.py
  crud.py
  services.py

tests/
  conftest.py
  test_create_employee.py
  test_get_employee.py
  test_list_employees.py
  test_update_employee.py
  test_delete_employee.py
  test_salary_calculation.py
  test_salary_metrics.py

About

Python FastAPI project implementing REST API using Test Driven Development (TDD) with pytest.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages