aboutsummaryrefslogtreecommitdiff
path: root/Module.Taskfile.yaml
diff options
context:
space:
mode:
Diffstat (limited to 'Module.Taskfile.yaml')
-rw-r--r--Module.Taskfile.yaml37
1 files changed, 29 insertions, 8 deletions
diff --git a/Module.Taskfile.yaml b/Module.Taskfile.yaml
index 1d33c85..8424a89 100644
--- a/Module.Taskfile.yaml
+++ b/Module.Taskfile.yaml
@@ -18,23 +18,44 @@ tasks:
- git reset --hard
- git remote update
- git pull origin {{ .BRANCH_NAME }} --verify-signatures
-
- #updates the project versions for all inlcuded .NET projects
- - dotnet-gitversion.exe /updateprojectfiles
test:
desc: 'Builds and runs noscrypt unit tests for vnbuild CI systems'
cmds:
- #run CI tests with utils enabled
- - cmd: task test -- -DNC_ENABLE_UTILS=ON
+ #ensure the debug library has been built for the current system before project tests are executed
+ - cmd: task build-debug -- -DNC_ENABLE_UTILS=ON
+ #library is already built, just need to test it
+ - cmd: task test-dev
+ - task: test-dotnet
+
+ #runs the test suite inside wsl linux environment
+ - cmd: echo 'Running WSL tests {{ if eq OS "windows" }}TRUE{{ else }}FALSE{{ end }}'
+ silent: true
- cmd: wsl task test -- -DNC_ENABLE_UTILS=ON
+ platforms: [ windows ]
+ #run memory check
- cmd: wsl task memcheck
-#called by build pipeline to build module
- build:
+ test-dotnet:
+ vars:
+ LIB_NAME: '{{ if eq OS "windows" }}noscrypt.dll{{ else }}libnoscrypt{{ end }}'
+ LIB_PATH: '{{ .USER_WORKING_DIR }}/build/{{ OS }}/{{ if eq OS "windows" }}debug/{{ end }}{{ .LIB_NAME }}'
+
cmds:
- - echo "building module {{.MODULE_NAME}}"
+ - cmd: echo "running tests for {{ .PROJECT_NAME }}"
+ silent: true
+ - cmd: dotnet test
+ {{ .CLI_ARGS }}
+ --logger "console;verbosity=detailed"
+ --framework {{ .FRAMEWORK | default "net8.0" }}
+ --configuration {{ .CONFIGURATION | default "Debug" }}
+ --environment VNLIB_SHARED_HEAP_DIAGNOSTICS="1"
+ --environment 'NOSCRYPT_DLL_PATH="{{ osClean .LIB_PATH }}"'
+#called by build pipeline to build module
+ build:
+ cmds: []
+
publish:
cmds:
#git archive in the module directory