mirror of
https://github.com/ajisaacs/OpenNest.git
synced 2026-11-03 14:41:37 -05:00
Core only uses System.Drawing.Color, which ships in the shared framework, so the System.Drawing.Common package (Windows-only beyond primitives) was an unneeded dependency of the cross-platform domain library. The desktop app keeps its own reference. CutParameters lives in OpenNest.Core but declared namespace OpenNest.Api, forcing Core and desktop files to import the Api namespace for a Core type. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
34 lines
854 B
C#
34 lines
854 B
C#
namespace OpenNest.Tests.Api;
|
|
|
|
public class CutParametersTests
|
|
{
|
|
[Fact]
|
|
public void Default_HasExpectedValues()
|
|
{
|
|
var cp = CutParameters.Default;
|
|
|
|
Assert.Equal(100, cp.Feedrate);
|
|
Assert.Equal(300, cp.RapidTravelRate);
|
|
Assert.Equal(TimeSpan.FromSeconds(0.5), cp.PierceTime);
|
|
Assert.Equal(Units.Inches, cp.Units);
|
|
}
|
|
|
|
[Fact]
|
|
public void Properties_AreSettable()
|
|
{
|
|
var cp = new CutParameters
|
|
{
|
|
Feedrate = 200,
|
|
RapidTravelRate = 500,
|
|
PierceTime = TimeSpan.FromSeconds(1.0),
|
|
LeadInLength = 0.25,
|
|
PostProcessor = "CL-707",
|
|
Units = Units.Millimeters,
|
|
};
|
|
|
|
Assert.Equal(200, cp.Feedrate);
|
|
Assert.Equal(0.25, cp.LeadInLength);
|
|
Assert.Equal("CL-707", cp.PostProcessor);
|
|
}
|
|
}
|