-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Resolved user test failures #32
Conversation
marrriamme
commented
Mar 8, 2025
- Исправила тесты
- Исправила метод GetUserByID
Makefile
Outdated
rm -rf coverage/ | ||
|
||
mocks: | ||
cd ./internal/transport && go generate |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Замени на go generate ./...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Сделано
Makefile
Outdated
clean: | ||
rm -rf bin/ | ||
|
||
run: build |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
У тебя уже есть run
Переименуй в run-build
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Спасибо, не заметила, поменяла
Makefile
Outdated
DOCKER_USERNAME=niknike | ||
IMAGE_NAME=bazaar | ||
TAG=latest |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Это наверх файла
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Сделано
internal/transport/user.go
Outdated
if !regexp.MustCompile(`[0-9]`).MatchString(password) { | ||
return errors.New("password must contain at least one number") | ||
} | ||
if !regexp.MustCompile(`[a-z]`).MatchString(password) { | ||
return errors.New("password must contain at least one lowercase letter") | ||
} | ||
if !regexp.MustCompile(`[A-Z]`).MatchString(password) { | ||
return errors.New("password must contain at least one uppercase letter") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Лучше опять же в 3 переменные вынести
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Вынесла