Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ public static IResourceBuilder<RustAppExecutableResource> AddRustApp(this IDistr
ArgumentException.ThrowIfNullOrWhiteSpace(workingDirectory, nameof(workingDirectory));

string[] allArgs = args is { Length: > 0 }
? ["run", ".", .. args]
: ["run", ".",];
? ["run", .. args]
: ["run"];

workingDirectory = Path.Combine(builder.AppHostDirectory, workingDirectory).NormalizePathForCurrentPlatform();
var resource = new RustAppExecutableResource(name, workingDirectory);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,7 @@ public async Task AddRustAppAddsAnnotationMetadata()
Assert.Equal("cargo", resource.Command);
var args = await resource.GetArgumentValuesAsync();
Assert.Collection(args,
arg => Assert.Equal("run", arg),
arg => Assert.Equal(".", arg));
arg => Assert.Equal("run", arg));
}

[Fact]
Expand All @@ -50,7 +49,6 @@ public async Task AddRustAppWithArgsAddsAnnotationMetadata()
var args = await resource.GetArgumentValuesAsync();
Assert.Collection(args,
arg => Assert.Equal("run", arg),
arg => Assert.Equal(".", arg),
arg => Assert.Equal("--verbose", arg));
}
}
Loading