Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
17 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 26 additions & 0 deletions .github/.release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# .github/release.yml

changelog:
categories:
- title: 🏕 Features
labels:
- "*"
exclude:
labels:
- dependencies
- chore
- docs
- refactor
- style
- test
- fix
- title: 🐛 Bug Fixes
labels:
- bug
- fix
- title: 📚 Documentation
labels:
- docs
- title: 🔄 Refactoring
labels:
- refactor
28 changes: 28 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: Run Tests

on:
pull_request:
branches: [ main, develop ]
push:
branches: [ main, develop ]

jobs:
test:
name: Run Tests and Lint
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3

- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: '1.23.0'
cache: true

- name: Install dependencies
run: go mod download

- name: Run Tests
run: |
make test
2 changes: 1 addition & 1 deletion .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ linters:
- ineffassign
- typecheck

issues:
issues:
exclude-use-default: false
max-same-issues: 5
max-issues-per-linter: 0
Expand Down
17 changes: 17 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -83,3 +83,20 @@ swagger-3-0: install-swag
swagger-fix-refs:
@./scripts/fix_swagger_refs.sh




.PHONY: test test-verbose test-coverage

# Run all tests
test:
go test -v -race ./internal/...

# Run tests with verbose output
test-verbose:
go test -v ./internal/...

# Run tests with coverage report
test-coverage:
go test -coverprofile=coverage.out ./internal/...
go tool cover -html=coverage.out -o coverage.html
735 changes: 494 additions & 241 deletions README.md

Large diffs are not rendered by default.

125 changes: 0 additions & 125 deletions Untitled-1.yaml

This file was deleted.

19 changes: 18 additions & 1 deletion cmd/server/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ import (
"github.com/omkar273/codegeeky/internal/config"
"github.com/omkar273/codegeeky/internal/httpclient"
"github.com/omkar273/codegeeky/internal/logger"
gateway "github.com/omkar273/codegeeky/internal/payment"
"github.com/omkar273/codegeeky/internal/postgres"
pubsubRouter "github.com/omkar273/codegeeky/internal/pubsub/router"
"github.com/omkar273/codegeeky/internal/repository"
Expand All @@ -31,7 +32,7 @@ import (
// @contact.email support@example.com

// @host localhost:8080
// @BasePath /api/v1
// @BasePath /v1

// @securityDefinitions.apikey Authorization
// @in header
Expand Down Expand Up @@ -70,6 +71,9 @@ func main() {
// http client
httpclient.NewDefaultClient,

// payment gateway registry
gateway.InitializeProviders,

// user repository
repository.NewUserRepository,

Expand All @@ -82,6 +86,15 @@ func main() {
// discount repository
repository.NewDiscountRepository,

// payment repository
repository.NewPaymentRepository,

// internship enrollment repository
repository.NewInternshipEnrollmentRepository,

// internship batch repository
repository.NewInternshipBatchRepository,

// pubsub router
pubsubRouter.NewRouter,
),
Expand All @@ -99,8 +112,12 @@ func main() {
service.NewUserService,
service.NewOnboardingService,
service.NewInternshipService,
service.NewInternshipBatchService,
service.NewCategoryService,
service.NewDiscountService,
service.NewPricingService,
service.NewPaymentService,
service.NewInternshipEnrollmentService,
))

// factory layer
Expand Down
Loading
Loading