Skip to content

Fix message supplier coverage in AssertTests - #37255

Open
noojung wants to merge 1 commit into
spring-projects:mainfrom
noojung:fix/assert-tests
Open

Fix message supplier coverage in AssertTests#37255
noojung wants to merge 1 commit into
spring-projects:mainfrom
noojung:fix/assert-tests

Conversation

@noojung

@noojung noojung commented Sep 7, 2026

Copy link
Copy Markdown
Contributor

Despite their names, noNullElementsWithEmptyCollection() and noNullElementsWithEmptyCollectionAndMessageSupplier() had identical logic:

	@Test
	void noNullElementsWithEmptyCollection() {
		assertThatCode(() ->
				Assert.noNullElements(emptyList(), "enigma"))
			.doesNotThrowAnyException();
	}

	@Test
	void noNullElementsWithEmptyCollectionAndMessageSupplier() {
		assertThatCode(() ->
				Assert.noNullElements(emptyList(), "enigma"))
			.doesNotThrowAnyException();
	}

This PR updates noNullElementsWithEmptyCollectionAndMessageSupplier() to pass a message supplier and exercise the intended overload.

Signed-off-by: Hyunwoo Jung <hyunwoojung@kakao.com>
@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged or decided on label Sep 7, 2026
@bclozel bclozel added the in: core Issues in core modules (aop, beans, core, context, expression) label Sep 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

in: core Issues in core modules (aop, beans, core, context, expression) status: waiting-for-triage An issue we've not yet triaged or decided on

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants