mirror of
https://github.com/netchx/netch.git
synced 2026-04-29 21:59:34 +08:00
Update SS/SSR Parameter
This commit is contained in:
@@ -74,6 +74,13 @@ namespace UnitTest
|
||||
public string? udp { get; set; } = null;
|
||||
}
|
||||
|
||||
private class Number : ParameterBase
|
||||
{
|
||||
public ushort a { get; set; } = 1;
|
||||
|
||||
public int b { get; set; } = 1;
|
||||
}
|
||||
|
||||
[TestMethod]
|
||||
public void Test()
|
||||
{
|
||||
@@ -85,6 +92,7 @@ namespace UnitTest
|
||||
Assert.AreEqual(new FlagAndOptional().ToString(), "--a");
|
||||
Assert.ThrowsException<RequiredArgumentValueInvalidException>(() => { _ = new RequiredEmpty().ToString(); });
|
||||
Assert.ThrowsException<RequiredArgumentValueInvalidException>(() => { _ = new RequiredNull().ToString(); });
|
||||
Assert.AreEqual(new Number().ToString(), "--a 1 --b 1");
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user