diff options
author | Andrei Karas <akaras@inbox.ru> | 2016-06-12 18:22:06 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2016-06-12 18:22:06 +0300 |
commit | 1f4538fdab078b642e4f20c49822eb818a27852f (patch) | |
tree | 1fbb3eed3db40e5aae1cd124c4705c967a1e0d30 | |
parent | be02d139535aefaaeda2db36211186fce3de01b7 (diff) | |
download | deheader-1f4538fdab078b642e4f20c49822eb818a27852f.tar.gz deheader-1f4538fdab078b642e4f20c49822eb818a27852f.tar.bz2 deheader-1f4538fdab078b642e4f20c49822eb818a27852f.tar.xz deheader-1f4538fdab078b642e4f20c49822eb818a27852f.zip |
Add test for #elif.
-rw-r--r-- | .gitlab-ci.yml | 18 | ||||
-rw-r--r-- | tools/ci/samples/test10.cpp | 12 | ||||
-rw-r--r-- | tools/ci/samples/test10.h | 13 |
3 files changed, 43 insertions, 0 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 031df72..8c2a711 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -146,6 +146,24 @@ test9_h: tags: - docker +test10_cpp: + stage: build + script: + - ./tools/ci/jobs/deheader.sh "g++-5" "" test10.cpp + - ./tools/ci/jobs/deheadererror.sh "include1.h" + image: debian:unstable + tags: + - docker + +test10_h: + stage: build + script: + - ./tools/ci/jobs/deheader.sh "g++-5" "" test10.h + - ./tools/ci/jobs/deheadererror.sh "include2.h" + image: debian:unstable + tags: + - docker + # reports success: diff --git a/tools/ci/samples/test10.cpp b/tools/ci/samples/test10.cpp new file mode 100644 index 0000000..a983c34 --- /dev/null +++ b/tools/ci/samples/test10.cpp @@ -0,0 +1,12 @@ +#include "test10.h" + +#ifndef QQQ +#include "include1.h" +#elif defined(ZZZ) +#include "include3.h" +#endif // QQQ + +int function1() +{ + return 0; +} diff --git a/tools/ci/samples/test10.h b/tools/ci/samples/test10.h new file mode 100644 index 0000000..5450ec6 --- /dev/null +++ b/tools/ci/samples/test10.h @@ -0,0 +1,13 @@ +#ifndef TEST10 +#define TEST10 + +#ifndef QQQ +#include "include2.h" +#elif !defined(ZZZ) +#include "include4.h" +#endif // QQQ + +int function1(); + +#define ZZZ +#endif // TEST10 |