From 9cb473cdd6a45cd6cfa64ab634cd3f05818be5ed Mon Sep 17 00:00:00 2001 From: Josh Soref <2119212+jsoref@users.noreply.github.com> Date: Thu, 25 Jan 2024 03:37:32 -0500 Subject: [PATCH] Improve error report for invalid action.yml --- src/Runner.Worker/ActionManifestManager.cs | 2 +- src/Test/L0/Worker/ActionManifestManagerL0.cs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Runner.Worker/ActionManifestManager.cs b/src/Runner.Worker/ActionManifestManager.cs index 6b46e6a4e92..351c2427daf 100644 --- a/src/Runner.Worker/ActionManifestManager.cs +++ b/src/Runner.Worker/ActionManifestManager.cs @@ -144,7 +144,7 @@ public ActionDefinitionData Load(IExecutionContext executionContext, string mani executionContext.Error(error.Message); } - throw new ArgumentException($"Fail to load {fileRelativePath}"); + throw new ArgumentException($"Failed to load {fileRelativePath}"); } if (actionDefinition.Execution == null) diff --git a/src/Test/L0/Worker/ActionManifestManagerL0.cs b/src/Test/L0/Worker/ActionManifestManagerL0.cs index 385ae94633f..91f604c0645 100644 --- a/src/Test/L0/Worker/ActionManifestManagerL0.cs +++ b/src/Test/L0/Worker/ActionManifestManagerL0.cs @@ -757,7 +757,7 @@ public void Load_CompositeActionNoUsing() //Assert var err = Assert.Throws(() => actionManifest.Load(_ec.Object, action_path)); - Assert.Contains($"Fail to load {action_path}", err.Message); + Assert.Contains($"Failed to load {action_path}", err.Message); _ec.Verify(x => x.AddIssue(It.Is(s => s.Message.Contains("Missing 'using' value. 'using' requires 'composite', 'docker', 'node12', 'node16' or 'node20'.")), It.IsAny()), Times.Once); } finally