aboutsummaryrefslogtreecommitdiff
path: root/test cases
AgeCommit message (Collapse)AuthorFilesLines
2020-09-06Merge pull request #7689 from scivision/fortran_incJussi Pakkanen7-26/+30
correct Fortran include algorithm
2020-09-04introspect: add test dependencies info to test/benchmark JSONPaolo Bonzini2-2/+10
Add the ids of any target that needs to be rebuilt before running the tests as computed by the backend, to the introspection data for tests and benchmarks. This also includes anything that appears on the test's command line. Without this information, IDEs must update the entire build before running any test. They can now instead selectively build the test executable itself and anything that is needed to run it. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2020-09-03tests: add fortran cmake subproject include testMichael Hirsch7-26/+30
ci:unused_arg: update ninja version to work with fortran+cmake
2020-09-02cuda: bump CUDA version since 3.0 is no longer supportedDaniel Mensinger1-2/+2
2020-09-02Special case meson.version().version_compare() statementXavier Claessens1-0/+17
when that statement gets evaluated, the interpreter remembers the version target and if it was part of the evaluation of a `if` condition then the target meson version is temporally overriden within that if-block. Fixes: #7590
2020-09-02Add test case for cuda compiler setting fixMatt Madison3-0/+40
Signed-off-by: Matt Madison <matt@madison.systems>
2020-08-30CMake module: Allow paths of generated CMake sources for include directoriesSebastian WĂŒrl3-2/+13
2020-08-30Be stricter when detecting Windows/CygwinChristoph Reiter1-1/+1
This removes the check for "mingw" for platform.system(). The only case I know where "mingw" is return is if using a msys Python under a msys2 mingw environment. This combination is not really supported by meson and will result in weird errors, so remove the check. The second change is checking sys.platform for cygwin instead of platform.system(). The former is document to return "cygwin", while the latter is not and just returns uname(). While under Cygwin it uname() always starts with "cygwin" it's not hardcoded in MSYS2 and starts with the environment name. Using sys.platform is safer here. Fixes #7552
2020-08-27test: Add 'dir' support for installed files in test.jsonDaniel Mensinger2-397/+2
This is useful for automatically generated docs (doxygen, hotdoc) with a lot of generated files that may differ with different versions of the generator.
2020-08-27tests: update .gitignoreDaniel Mensinger2-0/+2
2020-08-27tests: fix lchmod check for glibc >= 2.32 (fixes #6784)Daniel Mensinger1-6/+14
2020-08-18Interpreter: Fix c_stdlib usageXavier Claessens6-0/+82
- Exceptions raised during subproject setup were ignored. - Allow c_stdlib in native file, was already half supported. - Eliminate usage of subproject variable name by overriding '<lang>_stdlib' dependency name.
2020-08-18prevent disabler() object from overwriting arrays (#7484)Elliot2-0/+10
* prevent disabler object from overwriting arrays fixes #7107 * fix failing test forgot that func() != func(void) in c
2020-08-13add testcase for issue #5182Paolo Bonzini1-0/+3
Issue #5182 (" extract_objects returns duplicate objects") has been fixed. Add a testcase to ensure it does not regress.
2020-08-12Test for spurious warning from get_target_filenamePaolo Bonzini3-0/+10
Fixed by #7494 without a test, so here's a test. Extracted from https://github.com/mesonbuild/meson/pull/7539
2020-08-09cmake: Detect custom command targets in compiler argsDaniel Mensinger3-0/+19
This is required to make `-include /path/to/custom/target.hpp` work. This setup is used by wxWidgets and this PR is required to use wxWidgets as a CMake subproject.
2020-08-08mtest: fix skipping with various prefixesMarc-André Lureau1-0/+1
According to the specification: https://testanything.org/tap-specification.html#skipping-tests The harness should report the text after # SKIP\S*\s+ as a reason for skipping. (it's not exactly like the TODO directive, the phrasing/presentation of the spec could be improved).
2020-08-08common/234: avoid intermittent failure by dynamic path length generationMichael Hirsch5-20/+39
2020-08-07cmake: make the traceparser permissive by default (fixes #7501)Daniel Mensinger1-0/+3
2020-08-07interpreter: Lower case languages before checking if 'c' is in the listXavier Claessens1-1/+2
Fixes: #7495
2020-08-06cmake: Fix failing test case. Followup to #7527.Daniel Mensinger1-1/+1
2020-08-05Merge pull request #7527 from mensinda/cnFixExeJussi Pakkanen5-17/+39
cmake: resolve IMPORTED executables in custom commands (fixes #7509)
2020-08-05mtest: TestResult.SKIP is not a failure (#7525)Simon McVittie4-0/+57
* mtest: TestResult.SKIP is not a failure If some but not all tests in a run were skipped, then the overall result is given by whether there were any failures among the non-skipped tests. Resolves: https://github.com/mesonbuild/meson/issues/7515 Signed-off-by: Simon McVittie <smcv@debian.org> * Add test-cases for partially skipped TAP tests issue7515.txt is the output of one of the real TAP tests in gjs, which failed as a result of #7515. The version inline in meson.build is a minimal reproducer. Signed-off-by: Simon McVittie <smcv@debian.org>
2020-08-04tests/common/227: remove unneeded is_git_checkoutMichael Hirsch, Ph.D1-12/+6
2020-08-04tests/common/227: don't have symlink in GitMichael Hirsch2-3/+4
Windows Git users with symlinks have a constantly dirty repo from this "a_symlink". This change generates a symlink in the build directory when the test is run.
2020-08-04tests: Disable Boost extralib test on macOSSimon McVittie1-1/+5
Since upgrading Boost to version 1.73, this test segfaults on macOS when dynamically linked. Disable it to keep the rest of the CI reliable. Mitigates: #7535 Signed-off-by: Simon McVittie <smcv@debian.org>
2020-08-03cmake: Only run the cmake_module_path test for CMake >= 3.12Daniel Mensinger2-16/+6
2020-08-03cmake: resolve IMPORTED executables in custom commands (fixes #7509)Daniel Mensinger3-1/+33
2020-08-01run dircondensor.pyDylan Baker30-2/+2
2020-08-01machine-files: give better error messages about using integersDylan Baker7-0/+21
2020-07-30Allow setting project options from cross or native filesDylan Baker2-0/+4
This allows adding a `[project options]` section to a cross or native file that contains the options defined for a project in it's meson_option.txt file.
2020-07-30pkgconfig: Fix various corner casesXavier Claessens3-1/+47
See unit tests for the exact scenarios this PR fixes.
2020-07-30Merge pull request #7494 from keszybz/fix-two-warningsJussi Pakkanen2-2/+3
Fix two warnings
2020-07-28Only emit warning about "native:" on projects with minimum required versionZbigniew Jędrzejewski-Szmek2-2/+3
'native:' keyword was only added in 0.54. For projects declaring meson_version >= 0.54, warn, because those projects can and should set the keyword. For older projects declaring support for older versions, don't warn and use the default implicitly. Fixes https://github.com/mesonbuild/meson/issues/6849.
2020-07-28ninjabackend: check if target has compiler attributeMarcel Hollerbach1-1/+3
otherwise we are getting errors like: Traceback (most recent call last): File "/usr/local/lib/python3.6/dist-packages/mesonbuild/mesonmain.py", line 131, in run return options.run_func(options) File "/usr/local/lib/python3.6/dist-packages/mesonbuild/msetup.py", line 245, in run app.generate() File "/usr/local/lib/python3.6/dist-packages/mesonbuild/msetup.py", line 159, in generate self._generate(env) File "/usr/local/lib/python3.6/dist-packages/mesonbuild/msetup.py", line 215, in _generate intr.backend.generate() File "/usr/local/lib/python3.6/dist-packages/mesonbuild/backend/ninjabackend.py", line 518, in generate self.generate_coverage_rules() File "/usr/local/lib/python3.6/dist-packages/mesonbuild/backend/ninjabackend.py", line 991, in generate_coverage_rules self.generate_coverage_command(e, []) File "/usr/local/lib/python3.6/dist-packages/mesonbuild/backend/ninjabackend.py", line 975, in generate_coverage_command for compiler in target.compilers.values(): AttributeError: 'RunTarget' object has no attribute 'compilers' This extends the 109 generatecode test case to also define a test, so coverage can really detect something.
2020-07-22coredata: Make warning_level per subproject builtin optionXavier Claessens3-2/+9
2020-07-21Add boost_root support to properties files (#7210)cmcneish12-0/+23
* Add boost_root support to properties files This commit implements `boost_root`, `boost_includedir`, and `boost_librarydir` variable support to native and cross properties files. The search order is currently environment variables, then these variables, and finally a platform-dependent search. * Add preliminary boost_root / boost_includedir tests Each test contains a fake "version.hpp", as that's how boost detection is currently being done. We look for this file relative to the root directory, which probably shouldn't be allowed (it previously was for BOOST_LIBRARYDIR but not for BOOST_ROOT). It also cannot help with breakage detection in libraries, however it looks like this wasn't getting tested beforehand. I've given the two unique version numbers that shouldn't be present in any stock version of boost (001 and 002). * Add return type to detect_split_root * Return empty list when nothing found in BOOST_ROOT, rather than None * Update boost_root tests * Create nativefile.ini based on location of run_project_tests.py * Add fake libraries to ensure boost_librarydir is being used * Require all search paths for boost to be absolute * Redo boost search ordering To better match things like pkg-config, we now look through native/cross files, then environment variables, then system locations for boost installations. Path detection does not fall back from one method to the next for properties or environment variables--if boost_root, boost_librarydir, or boost_includedir is specified, they must be sufficient to find boost. Likewise for BOOST_ROOT and friends. pkg-config detection is still optional falling back to system-wide detection, for Conan. (Also, fix a typo in test 33's nativefile) * Correct return type for detect_roots * Correct boost dependency search order in documentation * Print debug information for boost library finding, to resolve CI issues * Handle native/cross file templates in a more consistent way All tests can now create a `nativefile.ini.in` if they need to use some parameter that the testing framework knows about but they can't. * Pass str--rather than PosixPath--to os.path.exists, for Python35 * Look for boost minor versions, rather than boost patch versions in test cases * Drop fake dylib versions of boost_regex * Prefer get_env_var to use of os.environ * Correct error reporting for relative BOOST_ROOT paths * Bump version this appears in. Also, change "properties file" to "machine file" as that appears to be the more common language.
2020-07-21summary: Wrap lines when printing listsXavier Claessens1-0/+1
When a list_sep is provided (e.g. ', ') all items are printed on the same line, which gets ugly on very long lists (e.g. list of plugins enabled).
2020-07-20string: add substring methodStéphane Cerveau1-0/+15
This method aims to offer a simple way to 'substring' an existing string with start and end values.
2020-07-19Print a warning when importing a stabilized moduleMarc-André Lureau2-0/+9
2020-07-19Stabilize keyval moduleMarc-André Lureau5-5/+5
We have experimented with the module for about a year in a qemu branch (https://wiki.qemu.org/Features/Meson), and we would like to start moving the build system to meson. For that, keyval should have the stability guarantees. Cc: Paolo Bonzini <pbonzini@redhat.com>
2020-07-19fix msvc not recognising b_ndebugElliot Haisley2-0/+16
fixes #7404
2020-07-12simplify/correct test logicMichael Hirsch3-33/+36
before this, tests were being skipped on Ubuntu 20.04 with Anaconda Python Now, all 5 tests success
2020-07-12some python test cases don't care about backend, so run them in any caseMichael Hirsch3-14/+29
2020-07-12raise SystemExit() generally preferred to sys.exit(1)Michael Hirsch5-20/+9
2020-07-12c lang not needed for this testMichael Hirsch1-1/+2
2020-07-12setuptools is not stdlib, but distutils isMichael Hirsch1-1/+1
2020-07-12Decrease version requirement to work on Xenial.Jussi Pakkanen1-2/+2
2020-07-01wrap: Add failing unit test for fallback consistencyXavier Claessens4-0/+22
Dependency 'foo' is overriden with 'foo_dep' so using fallback variable name 'bar_dep' should abort.
2020-07-01interpreter: Don't abort if dep isn't required and sub didn't overrideXavier Claessens2-1/+8