Commit Graph

17 Commits

Author SHA1 Message Date
ridiculousfish
f117addf7c Use lowercase CMake function names
This is a best practice to distinguish them from variables.
2020-03-14 16:11:35 -07:00
ridiculousfish
ba0c2d48d1 Teach CMake to code sign Mac executables
Perform an ad-hoc code signing with the hardened runtime.
This ensures that these executables can pass notarization.

The code signing ID is controlled by the MAC_CODESIGN_ID CMake
cache variable.
2020-02-18 12:55:11 -07:00
David Adam
3365410bde cmake: only define test policy on old versions
CMP0037 only reserves the test name if CTest is included on newer versions of CMake.

This commit fixes a build warning.
2019-11-01 20:58:40 +08:00
ridiculousfish
97c4794424 Properly mark tests_dir as a dependency of test_prep
Allows for running a subset of tests immediately after build system config.
2019-07-21 11:21:50 -07:00
Fabian Homborg
cdbd0891f7 Remove invocation tests
These are now all performed by littlecheck, so there's no need for the
entire target anymore.
2019-06-25 22:31:45 +02:00
David Adam
8f3a0dcc8b cmake: harmonise argument to foreach/endforeach
Fixes a warning introduced in 40d91b7e77.
2019-06-23 16:00:40 +08:00
ridiculousfish
40d91b7e77 Allow running test suites independently
This makes test_low_level, test_interactive, test_invocation, and
test_fishscript independent. This allows running a smaller subset of tests.

To prevent all tests running in parallel, we also have new targets
serial_test_low_level, serial_test_interactive, etc. which have the
dependency chain that enforces serial execution.
2019-06-22 14:17:10 -07:00
ridiculousfish
db703c273d Remove some stale comments from Tests.cmake
These comments were used to refer back to the autotools build, but the
autotools build is no more and CMake is now the source of truth.
2019-06-22 13:12:49 -07:00
ridiculousfish
fcf0593dfb Port printf tests to littlecheck and teach the tester how to run it
This adds support for .check files inside the tests directory. .check
files are tests designed to be run with littlecheck.

Port printf test to littlecheck and remove the printf.in test.
2019-06-16 14:10:41 -07:00
ridiculousfish
23d88e0e03 Add fish_test_helper executable
In tests we would like to arrange for an executable to invoke certain
system calls, e.g. to claim or relinquish control of the terminal. This is
annoying to do portably via e.g. perl. fish_test_helper is a little
program where we can add custom commands to make it act in certain ways.
2019-04-07 09:20:19 -07:00
ridiculousfish
11502c0d36 Teach cmake to run expect tests
Fixes #4794
2018-07-21 15:43:31 -07:00
David Adam
e1bc48492f [cmake] only copy tests for out-of-tree builds
Makes in-tree builds work again.
2018-02-01 22:46:27 +08:00
David Adam
8eb0608b00 [cmake] make build_lexicon_filter part of DocTargets only 2018-01-14 21:14:22 +08:00
ridiculousfish
8a78dca26f Remove PRE_BUILD from tests_dir target
It doesn't seem necessary and I can't justify what it's there for.
2018-01-10 19:38:21 -08:00
Markus Reitboeck
843ac2554d copy test files with ADD_CUSTOM_COMMAND
This will copy the files every time "make test" is called, so the files are never out of sync.

Fixes issue #4633
2018-01-10 19:10:39 -08:00
ridiculousfish
f563262cfd Mark tests as USES_TERMINAL
This allows the Ninja build to show the test output live.
This requires bumping the min required CMake version to 3.2 (from 3.1)
2017-12-21 12:48:17 -08:00
David Adam
396faebc08 Move CMakeFiles to cmake
Makes in-tree (ie `cmake .`) builds work.
2017-11-17 16:21:55 +08:00