Skip to content

Łukasz Krulik 228780#3

Open
FawBiotechnologist wants to merge 12 commits intoMTO-2022-pt:FawBiotechnologistfrom
FawBiotechnologist:master
Open

Łukasz Krulik 228780#3
FawBiotechnologist wants to merge 12 commits intoMTO-2022-pt:FawBiotechnologistfrom
FawBiotechnologist:master

Conversation

@FawBiotechnologist
Copy link

No description provided.

public void confirm() {
requireState(State.SUBMITTED);
long hoursElapsedAfterSubmittion = subbmitionDate.until(LocalDateTime.now(), ChronoUnit.HOURS);
long hoursElapsedAfterSubmittion = subbmitionDate.until((testPurposesDatatime == null) ? LocalDateTime.now() : testPurposesDatatime, ChronoUnit.HOURS);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

to nie jest dobre rozwiązanie wprowadza pan logikę wyliczanie daty "pod testy". Nie chodziło o to, aby do konstruktora przekazać "przesuniętą datę" (albo null - co oznacza brak przesunięcia). Zamówienie powinno wyliczać czas zgodnie z założeniami, ale być zależna od "zegara", który w testach można "zamockować"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants