Skip to content
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

Ignorer overflødige skjemafelt #805

Merged
merged 7 commits into from
Dec 16, 2024
Merged

Conversation

bjerga
Copy link
Contributor

@bjerga bjerga commented Dec 13, 2024

De mest interessante endringene er i InntektsmeldingUtils.kt.

Når vi utfører duplikatsjekk på innsendt skjema så bør vi ignorere felter som Spleis ikke har bedt om. Det fordi disse feltene vil bli vasket bort senere i løypa. Dvs. at når Spleis ikke har bedt om inntekt, så vil to skjema med ulik inntekt vil være helt like når vi sender dem til Spleis. Da bør vi behandle de to skjemaene som duplikater.

Merk at dette er en løsning på at frontend sender backend felter som er overflødige. Den endelige løsningen bør være at frontend ikke sender disse feltene, men det vil ta tid (og en designer) å løse.

@bjerga bjerga requested a review from a team as a code owner December 13, 2024 12:16
Comment on lines -42 to +44
val mockRedis = MockRedis(RedisPrefix.Innsending)
val mockRedisStore = mockk<RedisStore>(relaxed = true)
Copy link
Contributor Author

Choose a reason for hiding this comment

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

MockRedis er en mer avansert mock som må brukes i testene til de statefulle servicene. Endrer til en enkel mock her og i testene for flere andre stateless servicer.

fun `skal ikke lagre duplikat inntektsmelding`() {
fun `skal ikke lagre duplikat inntektsmeldingskjema`() {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Disse to testene var kliss like, så jeg fjernet den ene.

@bjerga bjerga marked this pull request as draft December 13, 2024 14:40
@bjerga
Copy link
Contributor Author

bjerga commented Dec 16, 2024

Testet OK.

@bjerga bjerga marked this pull request as ready for review December 16, 2024 11:29
@bjerga bjerga requested review from a team and removed request for a team December 16, 2024 11:29
Copy link
Contributor

@magnusae magnusae left a comment

Choose a reason for hiding this comment

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

Fant ingen ting å utsette på dette 💯

@bjerga bjerga merged commit 7cf0861 into main Dec 16, 2024
74 checks passed
@bjerga bjerga deleted the dev/ignorer-overfloedig-skjemafelt branch December 16, 2024 13:48
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