aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/klippy/cartesian.test4
-rw-r--r--test/klippy/corexy.test4
-rw-r--r--test/klippy/delta.test33
-rw-r--r--test/klippy/move.gcode22
-rw-r--r--test/klippy/out_of_bounds.test8
-rw-r--r--test/klippy/printers.test40
6 files changed, 111 insertions, 0 deletions
diff --git a/test/klippy/cartesian.test b/test/klippy/cartesian.test
new file mode 100644
index 00000000..42b00ca7
--- /dev/null
+++ b/test/klippy/cartesian.test
@@ -0,0 +1,4 @@
+# Test case for basic cartesian movement
+CONFIG ../../config/example.cfg
+DICTIONARY atmega2560-16mhz.dict
+GCODE move.gcode
diff --git a/test/klippy/corexy.test b/test/klippy/corexy.test
new file mode 100644
index 00000000..6e43bdf8
--- /dev/null
+++ b/test/klippy/corexy.test
@@ -0,0 +1,4 @@
+# Test case for basic corexy movement
+CONFIG ../../config/example-corexy.cfg
+DICTIONARY atmega2560-16mhz.dict
+GCODE move.gcode
diff --git a/test/klippy/delta.test b/test/klippy/delta.test
new file mode 100644
index 00000000..0cd132b1
--- /dev/null
+++ b/test/klippy/delta.test
@@ -0,0 +1,33 @@
+# Test case for basic movement on delta printers
+CONFIG ../../config/example-delta.cfg
+DICTIONARY atmega2560-16mhz.dict
+
+# Start by homing the printer. Also tests Z moves.
+G28
+
+# Perform an XY+Z move with infintesimal XY component
+G1 x0 y0 z15
+
+# Perform an XY move along Y axis (aligned with rear tower)
+G1 x0 y5 z15
+
+# Perform an XY+Z move along Y axis
+G1 x0 y-5 z10
+
+# Perform a Z move
+G1 x0 y-5 z15
+
+# Perform an XY move across all three towers
+G1 x2 y2 z10
+
+# Perform an XY+Z move with tiny Z movement
+G1 x2 y-10 z10.1
+
+# Move to far away position
+G1 x140 y0
+
+# Move to extreme position
+G1 x145 y0
+
+# Move to another extreme position
+G1 x145 y5
diff --git a/test/klippy/move.gcode b/test/klippy/move.gcode
new file mode 100644
index 00000000..30e2a02c
--- /dev/null
+++ b/test/klippy/move.gcode
@@ -0,0 +1,22 @@
+; Simple movement tests
+
+; Start by homing the printer.
+G28
+G1 F6000
+
+; Z / X / Y moves
+G1 Z1
+G1 X1
+G1 Y1
+
+; diagonal moves
+G1 X0 Y0
+G1 X1 Z2
+G1 X0 Y1 Z1
+
+; extrude only moves
+G1 E1
+G1 E0
+
+; regular extrude move
+G1 X0 Y0 E.01
diff --git a/test/klippy/out_of_bounds.test b/test/klippy/out_of_bounds.test
new file mode 100644
index 00000000..5375ea7e
--- /dev/null
+++ b/test/klippy/out_of_bounds.test
@@ -0,0 +1,8 @@
+# Test that basic bounds checks work
+CONFIG ../../config/example.cfg
+DICTIONARY atmega2560-16mhz.dict
+SHOULD_FAIL
+
+# Home the printer, and then attempt to move to an obviously bad location
+G28
+G1 Y9999
diff --git a/test/klippy/printers.test b/test/klippy/printers.test
new file mode 100644
index 00000000..0f315ac3
--- /dev/null
+++ b/test/klippy/printers.test
@@ -0,0 +1,40 @@
+# Basic sanity checks on the example printer config files
+GCODE move.gcode
+
+# Printers using the atmega2560
+DICTIONARY atmega2560-16mhz.dict
+CONFIG ../../config/generic-einsy-rambo.cfg
+CONFIG ../../config/generic-mini-rambo.cfg
+CONFIG ../../config/generic-rambo.cfg
+CONFIG ../../config/generic-ramps.cfg
+CONFIG ../../config/generic-rumba.cfg
+CONFIG ../../config/printer-anycubic-i3-mega-2017.cfg
+CONFIG ../../config/printer-anycubic-kossel-2016.cfg
+CONFIG ../../config/printer-creality-cr10s-2017.cfg
+CONFIG ../../config/printer-lulzbot-taz6-2017.cfg
+CONFIG ../../config/printer-makergear-m2-2012.cfg
+CONFIG ../../config/printer-seemecnc-rostock-max-v2-2015.cfg
+CONFIG ../../config/printer-wanhao-duplicator-i3-plus-2017.cfg
+
+# Printers using the atmega1284p
+DICTIONARY atmega1284p.dict
+CONFIG ../../config/generic-melzi.cfg
+CONFIG ../../config/printer-anet-a8-2017.cfg
+CONFIG ../../config/printer-anet-e10-2018.cfg
+CONFIG ../../config/printer-creality-cr10-2017.cfg
+CONFIG ../../config/printer-creality-cr10mini-2017.cfg
+CONFIG ../../config/printer-creality-ender3-2018.cfg
+CONFIG ../../config/printer-tronxy-x5s-2018.cfg
+CONFIG ../../config/printer-wanhao-duplicator-i3-v2.1-2017.cfg
+
+# Printers using the at90usb1286
+DICTIONARY at90usb1286.dict
+CONFIG ../../config/generic-printrboard.cfg
+
+# Printers using the sam3x8e
+DICTIONARY sam3x8e.dict
+CONFIG ../../config/generic-radds.cfg
+
+# Printers using the lpc176x
+DICTIONARY lpc176x.dict
+CONFIG ../../config/generic-smoothieboard.cfg