diff --git a/ProjectPlugins/CodexPlugin/CodexContainerRecipe.cs b/ProjectPlugins/CodexPlugin/CodexContainerRecipe.cs index 6a0b76e7..b18e1cfb 100644 --- a/ProjectPlugins/CodexPlugin/CodexContainerRecipe.cs +++ b/ProjectPlugins/CodexPlugin/CodexContainerRecipe.cs @@ -12,6 +12,8 @@ namespace CodexPlugin public const string MetricsPortTag = "codex_metrics_port"; public const string DiscoveryPortTag = "codex_discovery_port"; + public const string ProfilerExecTimeThreshold = "0.2s"; + // Used by tests for time-constraint assertions. public static readonly TimeSpan MaxUploadTimePerMegabyte = TimeSpan.FromSeconds(2.0); public static readonly TimeSpan MaxDownloadTimePerMegabyte = TimeSpan.FromSeconds(2.0); @@ -46,6 +48,7 @@ namespace CodexPlugin var discPort = CreateDiscoveryPort(config); AddEnvVar("CODEX_DISC_PORT", discPort); AddEnvVar("CODEX_LOG_LEVEL", config.LogLevelWithTopics()); + AddEnvVar("CODEX_EXEC_TIME_THRESHOLD", ProfilerExecTimeThreshold); if (config.PublicTestNet != null) { diff --git a/ProjectPlugins/CodexPlugin/CodexDockerImage.cs b/ProjectPlugins/CodexPlugin/CodexDockerImage.cs index bbb09c0b..77b76f80 100644 --- a/ProjectPlugins/CodexPlugin/CodexDockerImage.cs +++ b/ProjectPlugins/CodexPlugin/CodexDockerImage.cs @@ -2,7 +2,8 @@ { public class CodexDockerImage { - private const string DefaultDockerImage = "codexstorage/nim-codex:latest-dist-tests"; + private const string DefaultDockerImage = + "codexstorage/nim-codex:sha-49bb3d3-dist-tests"; public static string Override { get; set; } = string.Empty; diff --git a/Tests/CodexReleaseTests/NodeTests/ProfilerCheckTest.cs b/Tests/CodexReleaseTests/NodeTests/ProfilerCheckTest.cs new file mode 100644 index 00000000..bfbd60c3 --- /dev/null +++ b/Tests/CodexReleaseTests/NodeTests/ProfilerCheckTest.cs @@ -0,0 +1,20 @@ +using CodexTests; +using DistTestCore; +using NUnit.Framework; + +namespace CodexReleaseTests.NodeTests +{ + [TestFixture] + public class ProfilerCheckTest : CodexDistTest + { + [Test] + public void IsProfilingImage() + { + var node = StartCodex(); + var log = node.DownloadLog(); + node.Stop(waitTillStopped: false); + + log.AssertLogContains("Enabling profiling"); + } + } +}