Skip to content

Commit ca3621c

Browse files
committed
Added mocks and added comment/doc. Clean up.
1 parent 18da265 commit ca3621c

File tree

19 files changed

+646
-449
lines changed

19 files changed

+646
-449
lines changed

β€Ž.mockery.yamlβ€Ž

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,13 @@ resolve-type-alias: False
22
issue-845-fix: True
33

44
packages:
5+
github.com/AmadlaOrg/LibraryUtils/configuration:
6+
interfaces:
7+
IConfiguration:
8+
config:
9+
dir: "{{.InterfaceDir}}"
10+
mockName: "MockConfiguration"
11+
inpackage: True
512
github.com/AmadlaOrg/LibraryUtils/file:
613
interfaces:
714
IFile:
@@ -38,6 +45,27 @@ packages:
3845
dir: "{{.InterfaceDir}}"
3946
mockName: "MockGoGitRemote"
4047
inpackage: True
48+
github.com/AmadlaOrg/LibraryUtils/location:
49+
interfaces:
50+
ILocation:
51+
config:
52+
dir: "{{.InterfaceDir}}"
53+
mockName: "MockLocation"
54+
inpackage: True
55+
github.com/AmadlaOrg/LibraryUtils/tools/desktop:
56+
interfaces:
57+
IDesktop:
58+
config:
59+
dir: "{{.InterfaceDir}}"
60+
mockName: "MockToolsDesktop"
61+
inpackage: True
62+
github.com/AmadlaOrg/LibraryUtils/tools/document:
63+
interfaces:
64+
IDocument:
65+
config:
66+
dir: "{{.InterfaceDir}}"
67+
mockName: "MockToolsDocument"
68+
inpackage: True
4169
io/fs:
4270
interfaces:
4371
FileInfo:

β€ŽMakefileβ€Ž

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -40,10 +40,6 @@ clean: ## Clean bin and coverage files
4040
@rm -f coverage.out
4141
@rm -f .reports/*
4242

43-
build: ## Build code
44-
@echo "---> Build"
45-
@CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags="-s -w" -buildvcs=true -o bin/ ./
46-
4743
.PHONY: help
4844
help: ## Help
4945
@grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | sed 's/Makefile://' | sort | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}'

β€Žconfiguration/configuration.goβ€Ž

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,14 @@ package configuration
22

33
import "github.com/spf13/viper"
44

5+
// IConfiguration 🧩 Is the interface for the NewConfigurationService.
56
type IConfiguration interface {
67
AllPropertyNames() []string
78
AllProperties() map[string]any
89
Set(key string, defaultValue any)
910
}
11+
12+
// SConfiguration πŸ›οΈ Is the main structure for the NewConfigurationService.
1013
type SConfiguration struct {
1114
// πŸ“‡ appName - Is the of the application (normally all lowercase)
1215
appName string

β€Žconfiguration/mock_IConfiguration.goβ€Ž

Lines changed: 160 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

β€Žfile/mock_FileInfo.goβ€Ž

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

β€Žfile/mock_IFile.goβ€Ž

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

β€Žgit/mock_IGit.goβ€Ž

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

β€Žgit/mock_IGoGitRepository.goβ€Ž

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

β€Žgit/mock_IGoGitWorktree.goβ€Ž

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

β€Žgit/remote/mock_IGoGitRemote.goβ€Ž

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
Β (0)