aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2015-03-25 13:49:14 +0100
committerSven Gothel <[email protected]>2015-03-25 13:49:14 +0100
commitff2b708f8cb716a179f2de534c1694fce9434243 (patch)
treefb6f8a5dd5023ea2877d200e60f396d374c613a3
parent1608c8a7e616994ffb50339dbb2c5121c8060b53 (diff)
IncludeAbsoluteTest: Fix test on Windows: Use slashified absolut pathname as required by Preprocessorv2.3.1
-rw-r--r--src/test/java/com/jogamp/gluegen/jcpp/IncludeAbsoluteTest.java7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/test/java/com/jogamp/gluegen/jcpp/IncludeAbsoluteTest.java b/src/test/java/com/jogamp/gluegen/jcpp/IncludeAbsoluteTest.java
index e9d7b27..9008ebe 100644
--- a/src/test/java/com/jogamp/gluegen/jcpp/IncludeAbsoluteTest.java
+++ b/src/test/java/com/jogamp/gluegen/jcpp/IncludeAbsoluteTest.java
@@ -32,8 +32,13 @@ public class IncludeAbsoluteTest extends SingletonJunitCase {
final File file = new File(filepath);
assertTrue(file.exists());
+ final String slashifiedFilePath = IOUtil.slashify(file.getAbsolutePath(), true, false);
+ LOG.info("slashifiedFilePath: " + slashifiedFilePath);
- final String input = "#include <" + file.getAbsolutePath() + ">\n";
+ // Expects something like:
+ // WINDOWS: "/C:/projects/jogamp/gluegen/jcpp/src/test/resources/absolute.h"
+ // UNIX: "/projects/jogamp/gluegen/jcpp/src/test/resources/absolute.h"
+ final String input = "#include <" + slashifiedFilePath + ">\n";
LOG.info("Input: " + input);
final Preprocessor pp = new Preprocessor();
pp.addInput(new StringLexerSource(input, true));