Skip to content

Improve test coverage in PropertiesMeterFilterTests #14689

@wilkinsona

Description

@wilkinsona

#14684 identified a case that's not covered by PropertiesMeterFilterTests. We should add a test that verifies that the default is applied when there are properties set but they don't relate to the meter in question:

@Test
public void acceptWhenHasNoMatchingEnabledPropertyShouldReturnNeutral() {
	PropertiesMeterFilter filter = new PropertiesMeterFilter(
			createProperties("enable.something.else=false"));
	assertThat(filter.accept(createMeterId("spring.boot")))
			.isEqualTo(MeterFilterReply.NEUTRAL);
}

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions