# Better unit tests with Parameterized testing 📈

DevFeed: [Better unit tests with Parameterized testing 📈](<https://devfeed.tech/articles/better-unit-tests-with-parameterized-testing-25688.md>)

Original publisher: [Read original article](<https://sergiosastre.hashnode.dev/better-unit-tests-with-parameterized-testing>)

Author: Sergio Sastre Florez

Published: 2021-05-31T06:30:38Z

Content type: tutorial

Language: en

Sources: [Sergio's little tech corner](<https://devfeed.tech/sources/sergio-s-little-tech-corner.md>)

Topics: [Testing](<https://devfeed.tech/topics/testing.md>), [Kotlin](<https://devfeed.tech/topics/kotlin.md>), [Java](<https://devfeed.tech/topics/java.md>), [passwords](<https://devfeed.tech/topics/passwords.md>)

Tags: [android-app-development](<https://devfeed.tech/tags/android-app-development.md>), [best-practices](<https://devfeed.tech/tags/best-practices.md>), [data](<https://devfeed.tech/tags/data.md>), [java](<https://devfeed.tech/tags/java.md>), [kotlin](<https://devfeed.tech/tags/kotlin.md>), [password](<https://devfeed.tech/tags/password.md>), [self-improvement](<https://devfeed.tech/tags/self-improvement.md>), [set](<https://devfeed.tech/tags/set.md>), [tdd](<https://devfeed.tech/tags/tdd.md>), [test](<https://devfeed.tech/tags/test.md>), [testing](<https://devfeed.tech/tags/testing.md>), [tests](<https://devfeed.tech/tags/tests.md>), [unit-testing](<https://devfeed.tech/tags/unit-testing.md>), [unit-tests](<https://devfeed.tech/tags/unit-tests.md>), [verify](<https://devfeed.tech/tags/verify.md>), [writing](<https://devfeed.tech/tags/writing.md>)

## AI overview

This tutorial explains how parameterized or data-driven tests can improve unit-test quantity and quality. Using a password validator as an example, it discusses testing multiple inputs and expected outputs in JUnit 5 with Kotlin, with applicability to Java.

## Source excerpt

While writing Unit Tests, we often verify that given an input, the output of the method under test is the one expected. When you execute the same test with a different set of inputs and expected outputs several times, you come up with Data Driven Tes...