You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@logging.apache.org by Matt Sicker <bo...@gmail.com> on 2020/11/09 15:32:54 UTC

Re: [logging-log4j2] branch release-2.x updated: Fix failing test for me on a less powerful Mac mini.

See also https://issues.apache.org/jira/browse/LOG4J2-2923

On Mon, 9 Nov 2020 at 09:04, <gg...@apache.org> wrote:
>
> This is an automated email from the ASF dual-hosted git repository.
>
> ggregory pushed a commit to branch release-2.x
> in repository https://gitbox.apache.org/repos/asf/logging-log4j2.git
>
>
> The following commit(s) were added to refs/heads/release-2.x by this push:
>      new 8693331  Fix failing test for me on a less powerful Mac mini.
> 8693331 is described below
>
> commit 8693331a2fbf2a7f4b04d631a74a09cc08fa6559
> Author: Gary Gregory <ga...@gmail.com>
> AuthorDate: Mon Nov 9 10:04:35 2020 -0500
>
>     Fix failing test for me on a less powerful Mac mini.
>
>     Maven home: /usr/local/Cellar/maven/3.6.3_1/libexec
>     Java version: 1.8.0_272, vendor: AdoptOpenJDK, runtime:
>     /Library/Java/JavaVirtualMachines/adoptopenjdk-8.jdk/Contents/Home/jre
>     Default locale: en_US, platform encoding: UTF-8
>     OS name: "mac os x", version: "10.15.7", arch: "x86_64", family: "mac"
>
>       Model Name:       Mac mini
>       Model Identifier: Macmini8,1
>       Processor Name:   Quad-Core Intel Core i3
>       Processor Speed:  3.6 GHz
>       Number of Processors:     1
>       Total Number of Cores:    4
>       L2 Cache (per Core):      256 KB
>       L3 Cache: 6 MB
>       Memory:   8 GB
> ---
>  .../java/org/apache/logging/log4j/core/config/TestConfigurator.java | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/log4j-core/src/test/java/org/apache/logging/log4j/core/config/TestConfigurator.java b/log4j-core/src/test/java/org/apache/logging/log4j/core/config/TestConfigurator.java
> index e6d8541..5963f81 100644
> --- a/log4j-core/src/test/java/org/apache/logging/log4j/core/config/TestConfigurator.java
> +++ b/log4j-core/src/test/java/org/apache/logging/log4j/core/config/TestConfigurator.java
> @@ -261,14 +261,14 @@ public class TestConfigurator {
>          }
>          assertTrue(file.setLastModified(System.currentTimeMillis()), "setLastModified should have succeeded.");
>          TimeUnit.SECONDS.sleep(config.getWatchManager().getIntervalSeconds()+1);
> -        for (int i = 0; i < 17; ++i) {
> +        for (int i = 0; i < 100; ++i) {
>              logger.debug("Test message " + i);
>          }
>
>          // Sleep and check
> -        Thread.sleep(50);
> +        Thread.sleep(100);
>          if (is(theInstance(config)).matches(ctx.getConfiguration())) {
> -            Thread.sleep(500);
> +            Thread.sleep(2000);
>          }
>          final Configuration newConfig = ctx.getConfiguration();
>          assertThat("Configuration not reset", newConfig, is(not(theInstance(config))));
>