summaryrefslogtreecommitdiff
path: root/tests
Commit message (Collapse)AuthorAgeFilesLines
* Add -h and --flow (on|off|keep) to run-*-test-suite (#187)Tina Müller (tinita)2020-06-013-12/+139
| | | | | | | | | | | | | | | | With `--flow (keep|on)` run-parser-test-suite will output: +MAP {} +SEQ [] run-emitter-test-suite will then emit flow style collections if requested: echo 'foo: [bar, {x: y}]' | ./tests/run-parser-test-suite | ./tests/run-emitter-test-suite echo 'foo: [bar, {x: y}]' | ./tests/run-parser-test-suite \ --flow keep | ./tests/run-emitter-test-suite --flow keep Also: add that yaml_private.h include again that I had thrown out. Needed for printing directives. Wonder if there is a way to create a directive without using the private api.
* Remove unnecessary include and mallocTina Müller2020-05-211-2/+0
|
* Output error position in run-parser-test-suite.cTina Müller2020-05-211-1/+9
|
* Allow emitting 1.2 directiveTina Müller2020-04-191-8/+42
| | | | | | | | Before `1.1` was hardcoded in the emitter. * Also add --directive option to run-emitter-test-suite Allows to easily test how output looks like if %YAML directives are output.
* Squash a couple of warnings in example-deconstructor-altMichael Drake2019-06-061-3/+3
| | | | | | | | | | | example-deconstructor-alt.c: In function ‘main’: example-deconstructor-alt.c:649:51: warning: comparison between ‘yaml_sequence_style_t {aka enum yaml_sequence_style_e}’ and ‘enum yaml_mapping_style_e’ [-Wenum-compare] example-deconstructor-alt.c:650:36: warning: comparison between ‘yaml_sequence_style_t {aka enum yaml_sequence_style_e}’ and ‘enum yaml_mapping_style_e’ [-Wenum-compare]
* Remove stdbool0.2.2-pre2Tina Müller2019-02-281-5/+4
| | | | Might not be available everywhere
* Make declarations before other statementsTina Müller2019-02-281-3/+5
|
* Fix comparison in tests/run-emitter.cTina Müller2018-06-301-1/+1
|
* Fixed most compiler warnings -Wall -WextraReini Urban2018-01-086-63/+63
| | | | | | | | | | | repro: CFLAGS="-Wall -Wextra -Wunused-parameter -Wc++-compat" ./configure && make which we use for perl, and libyaml is now included in cperl. Tested with gcc-5 and clang-3.7 There are still a tons of format warnings (%d on 64bit) in example-deconstructor.c which I skipped.
* Fix problems in CI failures (travis and semaphore)Ingy döt Net2018-01-061-0/+0
| | | | | | | | | | | | | | | | | In the Makefile.am, switched out the fetch (which can have auth problems in certain envs) with a simple branch per @perlpunk++'s suggestion. With the new test branches, travis had a problem in that it only clones one branch and we need the other branch refs to be available. Fixed this by fetching the other branch refs. I also cleaned up the travis YAML file. The Ubuntu 14.04 docker image (used by semaphoreci) had an older git, without the worktree command, so I made it install the latest git from a ppa. Renamed tests/run-tests.sh to tests/run-all-tests.sh for tab completion conflict reasons.
* Move tests/run-test-suite to branch run-test-suiteIngy döt Net2017-12-2912-639/+2
| | | | | | | | | | | | | | | | with the intent that `make test-suite` will use it as a branch. This commit makes the libyaml and yaml-test-suite repos completely independent. The only thing in master is a Makefile rule for `make run-test-suite`. The run-test-suite branch takes care of everything else. This will keep the master branch history clean from any yaml-test-suite activity, while keeping everything up to date. Pinning will just work for whatever commit of master you run the tests from. The pinning work will all be done in the `run-test-suite` branch.
* Update libyaml-{parser,emitter}.listTina Müller2017-12-232-0/+92
| | | | | yaml-test-suite/data commit: daf799e 2017-12-23 "Regenerated data from master 1eacbab"
* Rewrite make test-suiteTina Müller2017-12-0210-110/+28
| | | | | | | | | | | | | | No recursive make anymore Remove MY_LD_LIBRARY_PATH and friends This is now done by the wrapper script Remove LIBYAML_DIR variable not needed anymore Merge ReadMe.md files to one
* Skip 5 tests in libyaml-emitter.listTina Müller2017-12-011-5/+0
|
* Improve CMake build systemJean-Christophe Fillion-Robin2017-11-302-0/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | New build options ----------------- * Add option BUILD_TESTING by default ON See https://cmake.org/cmake/help/v2.8.12/cmake.html#module:CTest * Simplify library type selection using standard option BUILD_SHARED_LIBS See https://cmake.org/cmake/help/v3.0/variable/BUILD_SHARED_LIBS.html yamlConfig.cmake ---------------- * Generate and install yamlConfig.cmake, yamlConfigVersion.cmake and yamlTargets.cmake * Bump CMake version and explicitly associate include dirs with targets See https://cmake.org/cmake/help/v3.0/manual/cmake-buildsystem.7.html#include-directories-and-usage-requirements * Ensure building against libyaml using "find_package(yaml)" uses expected compile options: Set HAVE_CONFIG_H as private compile option, YAML_DECLARE_STATIC as public Testing ------- * Build all examples from "tests" directory CMake Best practices -------------------- * configure "config.h" based on version info found in CMakeLists.txt * Ensure buildsystem re-generation listing sources (best-practice) It is not recommended to use GLOB to collect a list of source files from the source tree. If no CMakeLists.txt file changes when a source is added or removed then the generated build system cannot know when to ask CMake to regenerate. See https://cmake.org/cmake/help/v3.8/command/file.html Compilation warnings -------------------- * Set _CRT_SECURE_NO_WARNINGS if building using VisualStudio This will avoid warnings like this one: ``` C:\projects\libyaml\tests\run-emitter.c(268): warning C4996: 'fopen': This function or variable may be unsafe. Consider using fopen_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details. ``` Continuous Integration ---------------------- * travis: Install CMake >= 3.x using scikit-ci-addons * Add comments to appveyor.yml and run-tests.sh
* Remove deleted test from parser test list.Ingy döt Net2017-05-141-1/+0
|
* Switch test-suite run list from black to whitelistIngy döt Net2017-02-096-64/+267
| | | | | This way as the test suite grows, new tests won't disturb/break our testing.
* Skip edge case test M7A3Ingy döt Net2017-01-182-1/+2
|
* Get tests passing on DockerIngy döt Net2016-12-301-1/+2
| | | | | | | | | | The Dockerfiles needed to set LD_LIBRARY_PATH. For some bizarre reason I needed to build the parser and emitter twice. Since I plan to redo the building of these binaries later, this is OK for now, since all tests on all CICDs will pass. The docker stuff was needed by the semaphoreci system.
* Include libyaml-test and libyaml-parser-emitterIngy döt Net2016-12-3016-8/+812
| | | | | | | | | | Before the `make test-suite` command would clone yaml/libyaml-test which would in tuen clone yaml/libyaml-parser-emitter. Now they are part of the repository since they are not really useful outside the repository. They still clone the data branch of yaml/yaml-test-suite. That is where all the actual test data resides. That belongs outside the repo because it is intended for all yaml frameworks.
* Move Travis CI steps into a Bash scriptIngy döt Net2016-12-291-0/+30
| | | | | | | | This allows us to run the same Travis testing locally. Examples: ./tests/run-tests.sh
* Fix pointer and enum warnings in deconstructor-altIan Cordasco2016-12-291-66/+66
| | | | | This should cover the remainder of the warnings found on the Travis CI OSX builder.
* Fix pointer warnings in example-deconstructorIan Cordasco2016-12-291-83/+83
| | | | | | | There were several places in our test deconstructor where we were passing plain char[]s to functions expecting (yaml_char_t *)s. Since we will soon be forcing warnings to become errors, it makes sense to clean these up.
* Add -Wall to list of compile flagsIan Cordasco2016-12-291-1/+1
| | | | | Let's start warning on everything and we'll clean the warnings up as we go along.
* Fix -Wformat compilation errors in testsIan Cordasco2016-12-178-54/+54
| | | | | There were several warnings generated by formatting errors in the tests, this corrects the format strings and silences the warnings.
* Fixed error handling in run-emitter example.Kirill Simonov2016-07-041-1/+1
|
* Examples: prevent crashes on some input files (thank to Mathias Svensson).Kirill Simonov2016-06-262-9/+10
|
* Fixed double free in an example.Kirill Simonov2016-06-201-3/+0
|
* Undefine the NDEBUG directive for the test programs.Kirill Simonov2007-01-087-3/+33
|
* Add functions for constructing, parsing and emitting YAML documents.Kirill Simonov2007-01-077-60/+1443
|
* Older versions of gcc do not know about -Wno-pointer-sign.Kirill Simonov2006-08-151-1/+1
|
* Prepare the initial release.0.0.1Kirill Simonov2006-08-012-20/+20
|
* Add two examples and prepare the build system for distribution.Kirill Simonov2006-07-313-1/+1335
|
* Add the run-emitter test.Kirill Simonov2006-07-301-0/+323
|
* Fix Emitter bugs and leaks.Kirill Simonov2006-07-301-1/+1
|
* Fix some leaks, segfaults and warnings.Kirill Simonov2006-07-212-44/+70
|
* Refactor internal and external API.Kirill Simonov2006-07-215-58/+155
|
* Move yaml/yaml.h to yaml.h and merge version.c to api.c.Kirill Simonov2006-07-032-2/+2
|
* Complete buffering and encoding code.Kirill Simonov2006-06-011-78/+284
|
* Complete UTF-8 and UTF-16 decoders.Kirill Simonov2006-05-302-2/+146
| | | | Reader is mostly done (though untested).
* Add doxygen support.Kirill Simonov2006-05-212-7/+4
|
* Add the basic autoconf infrastructure.Kirill Simonov2006-05-202-0/+27