Skip to content

Commit

Permalink
enable another test
Browse files Browse the repository at this point in the history
  • Loading branch information
sjuergen committed Oct 9, 2024
1 parent f8690dc commit e66a87c
Showing 1 changed file with 19 additions and 19 deletions.
38 changes: 19 additions & 19 deletions test/TwoWayActuatorTest.st
Original file line number Diff line number Diff line change
Expand Up @@ -36,31 +36,31 @@ NAMESPACE Simatic.Ax.axftcmlib
busy := FALSE;
END_METHOD

{Test}
METHOD PUBLIC GoToWorkPosition_Swiches_Q_ToWorkPosition_On_And_Returns_Busy
cmd := _actuator.GoToWorkPosition();
busy := cmd.Busy();
AxUnit.Assert.Equal(expected := TRUE, actual := busy);
AxUnit.Assert.Equal(expected := TRUE, actual := _qToWork.IsOn());
AxUnit.Assert.Equal(expected := FALSE, actual := _qToHome.IsOn());
Equal(expected := TRUE, actual := _actuator.GetState() = ActuatorState#MoveToWorkPosition);
END_METHOD

// {Test}
// METHOD PUBLIC GoToWorkPosition_Returns_Done_When_end_position_is_already_reached
// _iInWorkPos.ReadCyclic(signal := TRUE);
// METHOD PUBLIC GoToWorkPosition_Swiches_Q_ToWorkPosition_On_And_Returns_Busy
// cmd := _actuator.GoToWorkPosition();
// busy := cmd.Busy();
// IF NOT(busy) THEN
// done := cmd.Done();
// END_IF;
// AxUnit.Assert.Equal(expected := FALSE, actual := busy);
// AxUnit.Assert.Equal(expected := TRUE, actual := done);
// AxUnit.Assert.Equal(expected := FALSE, actual := _qToWork.IsOn());
// AxUnit.Assert.Equal(expected := TRUE, actual := busy);
// AxUnit.Assert.Equal(expected := TRUE, actual := _qToWork.IsOn());
// AxUnit.Assert.Equal(expected := FALSE, actual := _qToHome.IsOn());
// Equal(expected := TRUE, actual := _actuator.GetState() = ActuatorState#InWorkPosition);
// Equal(expected := TRUE, actual := _actuator.GetState() = ActuatorState#MoveToWorkPosition);
// END_METHOD

{Test}
METHOD PUBLIC GoToWorkPosition_Returns_Done_When_end_position_is_already_reached
_iInWorkPos.ReadCyclic(signal := TRUE);
cmd := _actuator.GoToWorkPosition();
busy := cmd.Busy();
IF NOT(busy) THEN
done := cmd.Done();
END_IF;
AxUnit.Assert.Equal(expected := FALSE, actual := busy);
AxUnit.Assert.Equal(expected := TRUE, actual := done);
AxUnit.Assert.Equal(expected := FALSE, actual := _qToWork.IsOn());
AxUnit.Assert.Equal(expected := FALSE, actual := _qToHome.IsOn());
Equal(expected := TRUE, actual := _actuator.GetState() = ActuatorState#InWorkPosition);
END_METHOD

// {Test}
// METHOD PUBLIC Reaching_WorkPosition_Switches_Q_ToWorkPosition_Off_And_Returns_Done
// THIS.GoToWorkPosition_Swiches_Q_ToWorkPosition_On_And_Returns_Busy();
Expand Down

0 comments on commit e66a87c

Please sign in to comment.