Improve snapshot testing (#5856)
* Improve snapshot testing Signed-off-by: Nick Cameron <nrc@ncameron.org> * A snapshot a day keeps the bugs away! 📷🐛 * A snapshot a day keeps the bugs away! 📷🐛 --------- Signed-off-by: Nick Cameron <nrc@ncameron.org> Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
This commit is contained in:
@ -5,11 +5,7 @@ description: Artifact commands import_export.kcl
|
||||
[
|
||||
{
|
||||
"cmdId": "[uuid]",
|
||||
"range": [
|
||||
0,
|
||||
0,
|
||||
0
|
||||
],
|
||||
"range": [],
|
||||
"command": {
|
||||
"type": "edge_lines_visible",
|
||||
"hidden": false
|
||||
@ -17,11 +13,7 @@ description: Artifact commands import_export.kcl
|
||||
},
|
||||
{
|
||||
"cmdId": "[uuid]",
|
||||
"range": [
|
||||
0,
|
||||
0,
|
||||
0
|
||||
],
|
||||
"range": [],
|
||||
"command": {
|
||||
"type": "set_scene_units",
|
||||
"unit": "mm"
|
||||
@ -29,11 +21,7 @@ description: Artifact commands import_export.kcl
|
||||
},
|
||||
{
|
||||
"cmdId": "[uuid]",
|
||||
"range": [
|
||||
0,
|
||||
0,
|
||||
0
|
||||
],
|
||||
"range": [],
|
||||
"command": {
|
||||
"type": "object_visible",
|
||||
"object_id": "[uuid]",
|
||||
@ -42,11 +30,7 @@ description: Artifact commands import_export.kcl
|
||||
},
|
||||
{
|
||||
"cmdId": "[uuid]",
|
||||
"range": [
|
||||
0,
|
||||
0,
|
||||
0
|
||||
],
|
||||
"range": [],
|
||||
"command": {
|
||||
"type": "object_visible",
|
||||
"object_id": "[uuid]",
|
||||
|
||||
@ -1,12 +1,12 @@
|
||||
---
|
||||
source: kcl/src/simulation_tests.rs
|
||||
source: kcl-lib/src/simulation_tests.rs
|
||||
description: Result of parsing import_export.kcl
|
||||
---
|
||||
{
|
||||
"Ok": {
|
||||
"body": [
|
||||
{
|
||||
"end": 32,
|
||||
"end": 0,
|
||||
"path": {
|
||||
"type": "Kcl",
|
||||
"filename": "export_1.kcl"
|
||||
@ -16,14 +16,14 @@ description: Result of parsing import_export.kcl
|
||||
"items": [
|
||||
{
|
||||
"alias": null,
|
||||
"end": 12,
|
||||
"end": 0,
|
||||
"name": {
|
||||
"end": 12,
|
||||
"end": 0,
|
||||
"name": "three",
|
||||
"start": 7,
|
||||
"start": 0,
|
||||
"type": "Identifier"
|
||||
},
|
||||
"start": 7,
|
||||
"start": 0,
|
||||
"type": "ImportItem"
|
||||
}
|
||||
]
|
||||
@ -33,7 +33,7 @@ description: Result of parsing import_export.kcl
|
||||
"type": "ImportStatement"
|
||||
}
|
||||
],
|
||||
"end": 33,
|
||||
"end": 0,
|
||||
"start": 0
|
||||
}
|
||||
}
|
||||
|
||||
5
rust/kcl-lib/tests/import_export/unparsed.snap
Normal file
5
rust/kcl-lib/tests/import_export/unparsed.snap
Normal file
@ -0,0 +1,5 @@
|
||||
---
|
||||
source: kcl-lib/src/simulation_tests.rs
|
||||
description: Result of unparsing import_export.kcl
|
||||
---
|
||||
import three from "export_1.kcl"
|
||||
@ -0,0 +1,5 @@
|
||||
---
|
||||
source: kcl-lib/src/simulation_tests.rs
|
||||
description: Result of unparsing tests/import_export/export_1.kcl
|
||||
---
|
||||
export import three from "export_2.kcl"
|
||||
@ -0,0 +1,5 @@
|
||||
---
|
||||
source: kcl-lib/src/simulation_tests.rs
|
||||
description: Result of unparsing tests/import_export/export_2.kcl
|
||||
---
|
||||
export three = 3
|
||||
Reference in New Issue
Block a user