Skip to content

Unable to build jnaerator due to test failure #108

Description

@LowWeiLin

Hello!

I am following the instructions on building using mvn clean install, and I get the following test failure which stops the build. May I know how I can fix this? Thanks!

-------------------------------------------------------------------------------
Test set: com.ochafik.lang.jnaerator.JNAerationTest
-------------------------------------------------------------------------------
Tests run: 123, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 29.906 sec <<< FAILURE! - in com.ochafik.lang.jnaerator.JNAerationTest
test[55](com.ochafik.lang.jnaerator.JNAerationTest)  Time elapsed: 0.066 sec  <<< FAILURE!
java.lang.AssertionError: Error : com.ochafik.lang.compiler.CompilerUtils$CompilationError: Error in file:///TestJNA.java at line 9, col 17 :
    illegal start of expression

1:      import com.sun.jna.*;
2:      import com.sun.jna.ptr.*;
3:      import java.nio.*;
4:      import test.*;
5:      public class TestJNA {
6:          public static void main(String[] args) {
7:              // globals.test / JNA
8:              //#runtime(JNA)
9:>>>               import static test.TestLibrary.*;
10:         }
11:     }
Error in file:///TestJNA.java at line 9, col 24 :
    illegal start of expression

1:      import com.sun.jna.*;
2:      import com.sun.jna.ptr.*;
3:      import java.nio.*;
4:      import test.*;
5:      public class TestJNA {
6:          public static void main(String[] args) {
7:              // globals.test / JNA
8:              //#runtime(JNA)
9:>>>               import static test.TestLibrary.*;
10:         }
11:     }
Error in file:///TestJNA.java at line 9, col 35 :
    ';' expected

1:      import com.sun.jna.*;
2:      import com.sun.jna.ptr.*;
3:      import java.nio.*;
4:      import test.*;
5:      public class TestJNA {
6:          public static void main(String[] args) {
7:              // globals.test / JNA
8:              //#runtime(JNA)
9:>>>               import static test.TestLibrary.*;
10:         }
11:     }
Error in file:///TestJNA.java at line 9, col 48 :
    <identifier> expected

1:      import com.sun.jna.*;
2:      import com.sun.jna.ptr.*;
3:      import java.nio.*;
4:      import test.*;
5:      public class TestJNA {
6:          public static void main(String[] args) {
7:              // globals.test / JNA
8:              //#runtime(JNA)
9:>>>               import static test.TestLibrary.*;
10:         }
11:     }
Error in file:///TestJNA.java at line 9, col 49 :
    illegal start of expression

1:      import com.sun.jna.*;
2:      import com.sun.jna.ptr.*;
3:      import java.nio.*;
4:      import test.*;
5:      public class TestJNA {
6:          public static void main(String[] args) {
7:              // globals.test / JNA
8:              //#runtime(JNA)
9:>>>               import static test.TestLibrary.*;
10:         }
11:     }
 in :
{TestJNA.java=import com.sun.jna.*;
import com.sun.jna.ptr.*;
import java.nio.*;
import test.*;
public class TestJNA {
    public static void main(String[] args) {
        // globals.test / JNA
        //#runtime(JNA)
        import static test.TestLibrary.*;
    }
}}
    at org.junit.Assert.fail(Assert.java:88)
    at org.junit.Assert.assertTrue(Assert.java:41)
    at com.ochafik.lang.jnaerator.JNAerationTest$1.setFinished(JNAerationTest.java:184)
    at com.ochafik.lang.jnaerator.JNAerator.jnaerate(JNAerator.java:1066)
    at com.ochafik.lang.jnaerator.JNAerationTest.test(JNAerationTest.java:137)


Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions