knotfiles/tests/unit_test

25 lines
407 B
Plaintext
Executable File

#!/usr/bin/env nu
# test -- 运行单元测试
#
# Copyright (C) 2022 KAAAsS
def main [] {
print "开始运行全部单元测试"
main global_conf
main pkg
}
# 运行 dotfile 模块的单元测试
def "main global_conf" [] {
use ../knotfiles/dotfile/global_conf.nu
global_conf test
}
# 运行 pkg 模块的单元测试
def "main pkg" [] {
use ../knotfiles/pkg.nu
pkg test
}