Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
DerekBum committed Sep 9, 2024
1 parent cc95df5 commit 7bc50c6
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 271 deletions.
5 changes: 3 additions & 2 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,9 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Run tests and code coverage analysis
run: make -C build coverage
- name: Run tests without code coverage analysis
run: make -C build luatest-no-coverage
if: matrix.coveralls != true

- name: Send code coverage to coveralls.io
run: make -C build coveralls
Expand Down
4 changes: 4 additions & 0 deletions .luacov
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
exclude = {
'/test/',
'/.rocks/',
}
8 changes: 7 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,12 @@ add_custom_target(luatest
COMMENT "Run regression tests"
)

add_custom_target(luatest-no-coverage
COMMAND ${LUATEST} -v
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
COMMENT "Run regression tests without coverage"
)

add_custom_target(coverage
COMMAND ${LUACOV} ${PROJECT_SOURCE_DIR} && grep -A999 '^Summary' ${CODE_COVERAGE_REPORT}
DEPENDS ${CODE_COVERAGE_STATS}
Expand All @@ -49,7 +55,7 @@ add_custom_target(coverage
)

if(DEFINED ENV{GITHUB_TOKEN})
set(COVERALLS_COMMAND ${LUACOVCOVERALLS} --include ^http ^roles --verbose --repo-token $ENV{GITHUB_TOKEN})
set(COVERALLS_COMMAND ${LUACOVCOVERALLS} -r ${PROJECT_SOURCE_DIR} --verbose --repo-token $ENV{GITHUB_TOKEN})
else()
set(COVERALLS_COMMAND ${CMAKE_COMMAND} -E echo "Skipped uploading to coveralls.io: no token.")
endif()
Expand Down
85 changes: 0 additions & 85 deletions test/integration/httpd_role_test.lua

This file was deleted.

183 changes: 0 additions & 183 deletions test/unit/httpd_role_test.lua

This file was deleted.

0 comments on commit 7bc50c6

Please sign in to comment.