Fix exports and resulting test case

This commit is contained in:
NotTheDr01ds 2024-10-02 17:53:33 -04:00
parent 11e96b6c39
commit 612e0e2160
2 changed files with 12 additions and 18 deletions

View File

@ -1,19 +1,19 @@
# std.nu, `used` to load all standard library components
# Top-level commands: ellie, repeat, null-device, and "path add"
export use lib *
# std submodules
export module assert
export module bench
export module dt
export module formats
export module help
export module input
export module iter
export module log
export module assert
# Allow use of non-prefixed commands
# from these submodules when `use std *`
export use lib *
export use bench *
export use dt *
export use formats *
export use xml *
export use math *
export module math
export module xml
# Load main dirs command and all subcommands
export use dirs main
@ -26,9 +26,3 @@ export module dirs {
goto
]
}
# Backward compatibility
# Allow, for example, `formats to jsonl`
export module xml
export module formats
export module dt

View File

@ -6,6 +6,6 @@ def std_post_import [] {
assert length (scope commands | where name == "path add") 1
assert length (scope commands | where name == "ellie") 1
assert length (scope commands | where name == "repeat") 1
assert length (scope commands | where name == "from jsonl") 1
assert length (scope commands | where name == "datetime-diff") 1
assert length (scope commands | where name == "formats from jsonl") 1
assert length (scope commands | where name == "dt datetime-diff") 1
}