@@ -64,11 +64,11 @@ void shouldPassValidation() {
6464
6565 @ ParameterizedTest (name = "custom yaml = {arguments}" )
6666 @ ValueSource (booleans = {true , false })
67- public void shouldCreateMinimalValidConfiguration (boolean customYaml ){
67+ public void shouldCreateMinimalValidConfiguration (boolean customYaml ) {
6868 // Given
6969 Properties properties = new Properties ();
7070 properties .setProperty (JMX_SERVICE_URL , "jservice:jmx:rmi:///jndi/rmi://localhost:9010/jmxrmi" );
71- if (customYaml ){
71+ if (customYaml ) {
7272 properties .setProperty (JMX_CONFIG , "/file.yaml" );
7373 } else {
7474 properties .setProperty (JMX_TARGET_SYSTEM , "tomcat" );
@@ -81,15 +81,14 @@ public void shouldCreateMinimalValidConfiguration(boolean customYaml){
8181 assertThat (config .getServiceUrl ())
8282 .isEqualTo ("jservice:jmx:rmi:///jndi/rmi://localhost:9010/jmxrmi" );
8383
84- if (customYaml ){
84+ if (customYaml ) {
8585 assertThat (config .getJmxConfig ()).containsExactly ("/file.yaml" );
8686 assertThat (config .getTargetSystems ()).isEmpty ();
8787 } else {
8888 assertThat (config .getJmxConfig ()).isEmpty ();
8989 assertThat (config .getTargetSystems ()).containsExactly ("tomcat" );
9090 }
9191
92-
9392 assertThat (config .getSamplingInterval ())
9493 .describedAs ("default sampling interval must align to default metric export interval" )
9594 .isEqualTo (Duration .ofMinutes (1 ));
@@ -136,8 +135,7 @@ void shouldFailValidation_missingConfigPathAndTargetSystem() {
136135 // When and Then
137136 assertThatThrownBy (() -> fromConfig (TestUtil .configProperties (properties )))
138137 .isInstanceOf (ConfigurationException .class )
139- .hasMessage (
140- "at least one of 'otel.jmx.target.system' or 'otel.jmx.config' must be set" );
138+ .hasMessage ("at least one of 'otel.jmx.target.system' or 'otel.jmx.config' must be set" );
141139 }
142140
143141 @ Test
0 commit comments