@@ -697,7 +697,7 @@ mod tests {
697697 assert_eq ! ( program. to_instructions( ) . unwrap( ) , vec![
698698 Instruction :: G17 ( G17 { } ) ,
699699 Instruction :: Empty ( Empty { } ) ,
700- Instruction :: Comment ( Comment { text: "Tool change: Cylindrical tool diameter = 4 mm, length = 50 mm, direction = clockwise, spindle_speed = 5000 rpm, feed_rate = 400 mm/min" . to_string( ) } ) ,
700+ Instruction :: Comment ( Comment { text: "Tool change: type = Cylindrical, diameter = 4 mm, length = 50 mm, direction = clockwise, spindle_speed = 5000 rpm, feed_rate = 400 mm/min" . to_string( ) } ) ,
701701 Instruction :: G21 ( G21 { } ) ,
702702 Instruction :: G0 ( G0 { x: None , y: None , z: Some ( 50.0 ) } ) ,
703703 Instruction :: M5 ( M5 { } ) ,
@@ -892,7 +892,7 @@ mod tests {
892892 let expected_output = vec ! [
893893 Instruction :: G17 ( G17 { } ) ,
894894 Instruction :: Empty ( Empty { } ) ,
895- Instruction :: Comment ( Comment { text: "Tool change: Cylindrical tool diameter = 4 mm, length = 50 mm, direction = clockwise, spindle_speed = 5000 rpm, feed_rate = 400 mm/min" . to_string( ) } ) ,
895+ Instruction :: Comment ( Comment { text: "Tool change: type = Cylindrical, diameter = 4 mm, length = 50 mm, direction = clockwise, spindle_speed = 5000 rpm, feed_rate = 400 mm/min" . to_string( ) } ) ,
896896 Instruction :: G21 ( G21 { } ) ,
897897 Instruction :: G0 ( G0 { x: None , y: None , z: Some ( 50.0 ) } ) ,
898898 Instruction :: M5 ( M5 { } ) ,
@@ -914,7 +914,7 @@ mod tests {
914914 Instruction :: G1 ( G1 { x: Some ( 5.0 ) , y: Some ( 10.0 ) , z: Some ( -0.1 ) , f: None } ) ,
915915 Instruction :: G0 ( G0 { x: None , y: None , z: Some ( 10.0 ) } ) ,
916916 Instruction :: Empty ( Empty { } ) ,
917- Instruction :: Comment ( Comment { text: "Tool change: Conical tool angle = 45°, diameter = 1\" , length = 1.207\" , direction = clockwise, spindle_speed = 5000 rpm, feed_rate = 400\" /min" . to_string( ) } ) ,
917+ Instruction :: Comment ( Comment { text: "Tool change: type = Conical, angle = 45°, diameter = 1\" , length = 1.207\" , direction = clockwise, spindle_speed = 5000 rpm, feed_rate = 400\" /min" . to_string( ) } ) ,
918918 Instruction :: G21 ( G21 { } ) ,
919919 Instruction :: G0 ( G0 { x: None , y: None , z: Some ( 50.0 ) } ) ,
920920 Instruction :: M5 ( M5 { } ) ,
@@ -949,7 +949,7 @@ mod tests {
949949 let expected_output = vec ! [
950950 Instruction :: G17 ( G17 { } ) ,
951951 Instruction :: Empty ( Empty { } ) ,
952- Instruction :: Comment ( Comment { text: "Tool change: Conical tool angle = 45°, diameter = 1\" , length = 1.207\" , direction = clockwise, spindle_speed = 5000 rpm, feed_rate = 400\" /min" . to_string( ) } ) ,
952+ Instruction :: Comment ( Comment { text: "Tool change: type = Conical, angle = 45°, diameter = 1\" , length = 1.207\" , direction = clockwise, spindle_speed = 5000 rpm, feed_rate = 400\" /min" . to_string( ) } ) ,
953953 Instruction :: G21 ( G21 { } ) ,
954954 Instruction :: G0 ( G0 { x: None , y: None , z: Some ( 50.0 ) } ) ,
955955 Instruction :: M5 ( M5 { } ) ,
@@ -971,7 +971,7 @@ mod tests {
971971 Instruction :: G1 ( G1 { x: Some ( 20.0 ) , y: Some ( 20.0 ) , z: Some ( -0.1 ) , f: None } ) ,
972972 Instruction :: G0 ( G0 { x: None , y: None , z: Some ( 10.0 ) } ) ,
973973 Instruction :: Empty ( Empty { } ) ,
974- Instruction :: Comment ( Comment { text: "Tool change: Cylindrical tool diameter = 4 mm, length = 50 mm, direction = clockwise, spindle_speed = 5000 rpm, feed_rate = 400 mm/min" . to_string( ) } ) ,
974+ Instruction :: Comment ( Comment { text: "Tool change: type = Cylindrical, diameter = 4 mm, length = 50 mm, direction = clockwise, spindle_speed = 5000 rpm, feed_rate = 400 mm/min" . to_string( ) } ) ,
975975 Instruction :: G21 ( G21 { } ) ,
976976 Instruction :: G0 ( G0 { x: None , y: None , z: Some ( 50.0 ) } ) ,
977977 Instruction :: M5 ( M5 { } ) ,
@@ -1060,7 +1060,7 @@ mod tests {
10601060 let expected_output = vec ! [
10611061 Instruction :: G17 ( G17 { } ) ,
10621062 Instruction :: Empty ( Empty { } ) ,
1063- Instruction :: Comment ( Comment { text: "Tool change: Cylindrical tool diameter = 4 mm, length = 50 mm, direction = clockwise, spindle_speed = 5000 rpm, feed_rate = 400 mm/min" . to_string( ) } ) ,
1063+ Instruction :: Comment ( Comment { text: "Tool change: type = Cylindrical, diameter = 4 mm, length = 50 mm, direction = clockwise, spindle_speed = 5000 rpm, feed_rate = 400 mm/min" . to_string( ) } ) ,
10641064 Instruction :: G21 ( G21 { } ) ,
10651065 Instruction :: G0 ( G0 { x: None , y: None , z: Some ( 50.0 ) } ) ,
10661066 Instruction :: M5 ( M5 { } ) ,
@@ -1096,7 +1096,7 @@ mod tests {
10961096 Instruction :: G1 ( G1 { x: Some ( 15.0 ) , y: Some ( 20.0 ) , z: Some ( -0.1 ) , f: None } ) ,
10971097 Instruction :: G0 ( G0 { x: None , y: None , z: Some ( 5.0 ) } ) ,
10981098 Instruction :: Empty ( Empty { } ) ,
1099- Instruction :: Comment ( Comment { text: "Tool change: Conical tool angle = 45°, diameter = 1\" , length = 1.207\" , direction = clockwise, spindle_speed = 5000 rpm, feed_rate = 400\" /min" . to_string( ) } ) ,
1099+ Instruction :: Comment ( Comment { text: "Tool change: type = Conical, angle = 45°, diameter = 1\" , length = 1.207\" , direction = clockwise, spindle_speed = 5000 rpm, feed_rate = 400\" /min" . to_string( ) } ) ,
11001100 Instruction :: G21 ( G21 { } ) ,
11011101 Instruction :: G0 ( G0 { x: None , y: None , z: Some ( 50.0 ) } ) ,
11021102 Instruction :: M5 ( M5 { } ) ,
@@ -1175,7 +1175,7 @@ mod tests {
11751175 let expected_output = vec ! [
11761176 "G17" . to_string( ) ,
11771177 "" . to_string( ) ,
1178- ";(Tool change: Conical tool angle = 45°, diameter = 1\" , length = 1.207\" , direction = clockwise, spindle_speed = 5000 rpm, feed_rate = 400\" /min)" . to_string( ) ,
1178+ ";(Tool change: type = Conical, angle = 45°, diameter = 1\" , length = 1.207\" , direction = clockwise, spindle_speed = 5000 rpm, feed_rate = 400\" /min)" . to_string( ) ,
11791179 "G20" . to_string( ) ,
11801180 "G0 Z50" . to_string( ) ,
11811181 "M5" . to_string( ) ,
@@ -1197,7 +1197,7 @@ mod tests {
11971197 "G1 X20 Y20 Z-0.1" . to_string( ) ,
11981198 "G0 Z10" . to_string( ) ,
11991199 "" . to_string( ) ,
1200- ";(Tool change: Cylindrical tool diameter = 4 mm, length = 50 mm, direction = clockwise, spindle_speed = 5000 rpm, feed_rate = 400 mm/min)" . to_string( ) ,
1200+ ";(Tool change: type = Cylindrical, diameter = 4 mm, length = 50 mm, direction = clockwise, spindle_speed = 5000 rpm, feed_rate = 400 mm/min)" . to_string( ) ,
12011201 "G20" . to_string( ) ,
12021202 "G0 Z50" . to_string( ) ,
12031203 "M5" . to_string( ) ,
0 commit comments