Commit Graph

26 Commits (ee35d256aa485d35be1bab307ec9833780934577)

Author SHA1 Message Date
Lukas Werling ee35d256aa Add basic character classes to WildcardMatch() 2019-02-03 19:14:53 +01:00
Nicolas Hake 1ee3081de2 Add tests for StdMeshQuaternion 2017-04-10 19:13:04 +02:00
Nicolas Hake 4d33df9dfe Add tests for StdMeshVector 2017-04-10 19:13:04 +02:00
Lukas Werling 61bcdeba46 Remove separate c4value_test
Those test cases are included in the main "tests" binary as well.
2017-02-21 19:25:21 +01:00
Julius Michaelis 5f1ad6a5d7 Travis: fancy stuff
- gtest
 - colors
 - container based builds and GCC PCH (for a faster: "you failed")
2017-02-21 17:13:18 +01:00
Lukas Werling ee0b1c2599 Implement JSON serialization for C4Value 2017-02-17 23:29:01 +01:00
Lukas Werling a44bd69b2f Fix find_path for GMock on Arch Linux
The path is /usr/src/gmock/gmock-all.cc there.
2017-02-17 20:21:47 +01:00
Nicolas Hake b4127439ac Tests: Move aul diagnostics test to a separate file 2017-02-16 19:32:43 +01:00
Nicolas Hake e2fd7095c1 Merge branch 'ast'
# Conflicts:
#	src/C4Include.h
#	src/script/C4AulCompiler.cpp
#	src/script/C4AulParse.cpp
#	src/script/C4AulParse.h
#	src/script/C4ScriptHost.cpp
#	src/script/C4ScriptHost.h
#	tests/CMakeLists.txt
2016-10-20 17:33:02 +02:00
Nicolas Hake 266feeda4d Aul: Add AST generation tests
Just making sure the parser creates the AST the way we expect before we
hand off the code to the codegen.
2016-10-20 17:20:55 +02:00
Nicolas Hake 9caaf1e298 Aul: Split out error handling into a separate class for easier testing
By using an extern error handler in the script engine, we can mock that
handler and make sure something that should fail actually does, instead
of having to parse log messages.
2016-10-19 14:20:41 +02:00
Nicolas Hake 49a98e54a5 Add test for 57a35bf fix
So it turns out that the fix stops the engine from crashing, but it
still doesn't seem to generate valid code - Aul emits an internal error
at runtime.
2016-06-05 13:36:32 +02:00
Günther Brammer e790d2c327 Remove duplicated stubs for the scriptengine from mape 2016-01-24 02:09:14 +01:00
Nicolas Hake b7cffa5e82 Aul tests: Assert that Translate() warns when a translation is missing
I'm not a huge fan of testing for warnings by hijacking the logging
routines, but right now there's no way to exfiltrate warnings from Aul
any other way, so it'll have to do.

Overriding the logging functions from C4SimpleLog.cpp has the nice
additional advantage that expected runtime errors no longer get written
to stdout - this is okay because we're already checking that an
exception is thrown.
2016-01-23 13:49:09 +01:00
Nicolas Hake 24839204ce Tests: Add tests for Min, Max 2016-01-23 13:49:07 +01:00
Nicolas Hake b128f3a0a4 Tests: Split math tests out of base aul test file 2016-01-23 13:49:06 +01:00
Nicolas Hake 8136edb45a Pull tests into main CMake project 2016-01-23 13:49:05 +01:00
Nicolas Hake 7d186516a8 Tests: Move pthread dependency to gtest
The test binaries don't directly use pthread (but gtest does), so the
dependency should be added to gtest instead of the binary itself.
2015-12-13 14:33:02 +01:00
Nicolas Hake a9f93378fa Add some edge case tests for Aul arithmetic
These tests include testing for #1389 "Strange numbers on 64 bit".
2015-12-08 13:17:42 +01:00
Nicolas Hake 184b36d08a Add helper function to create test binaries 2015-12-08 13:17:38 +01:00
Nicolas Hake 2b83c1c778 Tests: Add C4ScriptStandaloneStubs.cpp to test project 2015-12-08 13:17:37 +01:00
Nicolas Hake 3f5efe65ad Tests: Link winmm 2015-02-08 15:05:14 +01:00
Nicolas Hake 849f8fe98d GTest: Also accept fused sources 2015-02-08 15:05:12 +01:00
Nicolas Hake 1a1cecadd4 Update license texts
Some files, most notably ObjC and test cases, hadn't been updated to use
the new license header. Fix this.
2015-02-08 15:05:11 +01:00
Oliver Schneider 3c3621072c cmake: properly removed gtest from the all target 2013-01-30 13:06:22 +01:00
Oliver Schneider c43a682785 tests: Compile gtest from source, add a few new tests
GTest does not ship precompiled binaries anymore. They are now compiled
using the CMakelists.txt from gtest.

Add basic unit tests for C4Value, DirectExec and C4StringTable.
2013-01-29 01:07:22 +01:00