UnitTests
This commit is contained in:
@@ -90,7 +90,7 @@ describe('GCode.receiveGCode', () => {
|
||||
expect(robot.sendCommand).toHaveBeenCalled()
|
||||
})
|
||||
|
||||
test('G28 setzt Home-Position', () => {
|
||||
test('G28 setzt Home-Position und löst Bewegung aus', () => {
|
||||
const robot = createDummyRobot()
|
||||
|
||||
GCode.receiveGCode(robot, 'G28')
|
||||
@@ -100,6 +100,8 @@ describe('GCode.receiveGCode', () => {
|
||||
expect(robot.y).toBe(robot.l1 + robot.l2 + robot.l3)
|
||||
expect(robot.phi).toBeCloseTo(-Math.PI / 2)
|
||||
expect(robot.theta).toBeCloseTo(Math.PI / 2)
|
||||
expect(robot.calculateAngles3D).toHaveBeenCalledTimes(1)
|
||||
expect(robot.sendCommand).toHaveBeenCalledTimes(1)
|
||||
})
|
||||
|
||||
test('Sende falsches Format', () =>{
|
||||
|
||||
Reference in New Issue
Block a user