Files
appRobotDriver/test/helpers/createDummyRobot.js
2026-04-04 07:57:24 +02:00

36 lines
553 B
JavaScript

// test/helpers/createDummyRobot.js
function createDummyRobot() {
return {
moveRelative: false,
// kartesische Position
x: 0,
y: 0,
z: 0,
phi: 0,
theta: 0,
psi: 0,
e: 0,
// Motoren
xMotor: 0,
alpha: 0,
beta: 0,
a: 0,
b: 0,
c: 0,
// Geometrie
l1: 10,
l2: 10,
l3: 10,
// Methoden → jest.fn erlaubt Call-Tracking
calculateAngles3D: jest.fn(),
calculatePositionFromMotorAngles: jest.fn(),
sendCommand: jest.fn()
}
}
module.exports = createDummyRobot