New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Command line debugging tests fail to run on Appveyor and cruise-control #1176

Open
JoshuaMcManus opened this Issue Dec 5, 2017 · 6 comments

Comments

@JoshuaMcManus

JoshuaMcManus commented Dec 5, 2017

Brief Description

Refer to Issue #882 to see changes made for command line debugging. (Seetestbed/test/cruise.compiler.CompilerErrorOutputTests and testbed/test/cruise.compiler.RuntimeErrorOutputTests)

The tests built for the command line debugging fix are not running on Appveyor and cruise-control machines. The majority of tests run fine on all other machines (including Travis), but all fail to find the text files used to verify the results in the other two machines.

The likely cause behind this is the use of relative paths in CompilerErrorUtil.java and RuntimeErrorUtil.java. These two utility functions expect the execution environment to be one directory deep from the root, and attempts to find the correct files relative to that position. Appveyor and cruise-control likely have a different execution environment and thus get an invalid path when opening the expected .txt files.

@JoshuaMcManus

This comment has been minimized.

Show comment
Hide comment
@JoshuaMcManus

JoshuaMcManus Dec 5, 2017

Note that @TimLethbridge disabled these tests on the machines in order to have the builds pass, when a fix is found you will want to remove the workaround.

JoshuaMcManus commented Dec 5, 2017

Note that @TimLethbridge disabled these tests on the machines in order to have the builds pass, when a fix is found you will want to remove the workaround.

@TimLethbridge

This comment has been minimized.

Show comment
Hide comment
@TimLethbridge

TimLethbridge Dec 5, 2017

Member

For the record, the workaround is to add the following line to _appveyor.xml and _cc.xml in the build directory. Removing these lines will re-activate the tests on those build servers.

<property name="excludeCompilerErrorOutput" value="true"/> 
Member

TimLethbridge commented Dec 5, 2017

For the record, the workaround is to add the following line to _appveyor.xml and _cc.xml in the build directory. Removing these lines will re-activate the tests on those build servers.

<property name="excludeCompilerErrorOutput" value="true"/> 
@TimLethbridge

This comment has been minimized.

Show comment
Hide comment
@TimLethbridge

TimLethbridge Oct 2, 2018

Member

This was only partially fixed. The commit message had the word partially, but the word fixed caused its complete closure. Reopening.

Member

TimLethbridge commented Oct 2, 2018

This was only partially fixed. The commit message had the word partially, but the word fixed caused its complete closure. Reopening.

@TimLethbridge TimLethbridge reopened this Oct 2, 2018

Debugging automation moved this from Done to To do Oct 2, 2018

@TimLethbridge

This comment has been minimized.

Show comment
Hide comment
@TimLethbridge

TimLethbridge Oct 6, 2018

Member

In Appveyor, if I activate the error output tests, then 6 of 9 tests fail:

jar:file:/usr/local/Cellar/ant/1.10.5/libexec/lib/ant.jar!/org/apache/tools/ant/P$
    [junit] TEST cruise.runtime.RuntimeErrorOutputTests FAILED

This is done in branch Java11AndIssue1176

What we need to do is to see why the

CompareOutputToExpected()

method at RuntimeErrorUtil.java

is failing in these 6 specific cases. I suspect it might be line-end
differences in Windows. The output is being compared to specific files
coming from directory.
testbed/test/cruise/runtime/expected

Member

TimLethbridge commented Oct 6, 2018

In Appveyor, if I activate the error output tests, then 6 of 9 tests fail:

jar:file:/usr/local/Cellar/ant/1.10.5/libexec/lib/ant.jar!/org/apache/tools/ant/P$
    [junit] TEST cruise.runtime.RuntimeErrorOutputTests FAILED

This is done in branch Java11AndIssue1176

What we need to do is to see why the

CompareOutputToExpected()

method at RuntimeErrorUtil.java

is failing in these 6 specific cases. I suspect it might be line-end
differences in Windows. The output is being compared to specific files
coming from directory.
testbed/test/cruise/runtime/expected

@YiranShu

This comment has been minimized.

Show comment
Hide comment
@YiranShu

YiranShu Oct 7, 2018

Contributor

@TimLethbridge
I pulled the branch Java11AndIssue1176. The full build fails immediately after I launch a full build. So I cannot see the 6 failing cases you mentioned. Following is the failure message I encountered.
yiran@yiran-virtual-machine:~/program/Umple/umple/build$ ant -Dmyenv=local
Buildfile: /home/yiran/program/Umple/umple/build/build.xml
[echo] Using myenv=local
[echo] Last Version: 1.29.1.4260.b21abf3a3

build:
[echo] Using myenv=local
[echo] Last Version: 1.29.1.4260.b21abf3a3

qaBuildingPage:
[echo] Starting Build
[copy] Copying 1 file to /home/yiran/program/Umple/umple/dist/qa
[echo] Building Sandbox for Testing Infrastructure
[echo] Using myenv=local
[echo] Last Version: 1.29.1.4260.b21abf3a3

build:
[echo] A sample build file for the Sandbox
[echo] Using myenv=local
[echo] Last Version: 1.29.1.4260.b21abf3a3

template.clean:
[delete] Deleting directory /home/yiran/program/Umple/umple/cruise.umple.validator/bin
[delete] Deleting directory /home/yiran/program/Umple/umple/cruise.umplificator/bin
[delete] Deleting directory /home/yiran/program/Umple/umple/sandbox/bin
[delete] Deleting directory /home/yiran/program/Umple/umple/dist/sandbox
[echo] Using myenv=local
[echo] Last Version: 1.29.1.4260.b21abf3a3

template.init:
[mkdir] Created dir: /home/yiran/program/Umple/umple/cruise.umple.validator/bin
[mkdir] Created dir: /home/yiran/program/Umple/umple/cruise.umplificator/bin
[mkdir] Created dir: /home/yiran/program/Umple/umple/sandbox/bin
[mkdir] Created dir: /home/yiran/program/Umple/umple/dist/sandbox
[echo] Using myenv=local
[echo] Last Version: 1.29.1.4260.b21abf3a3

umpleSandbox:
[java] Error: Unable to access jarfile /home/yiran/program/Umple/umple/dist/libs/umple-1.29.1.4260.b21abf3a3.jar
[echo] Using myenv=local
[echo] Last Version: 1.29.1.4260.b21abf3a3

qaLandingPage:
[echo] Creating a QA Landing Page
[copy] Copying 1 file to /home/yiran/program/Umple/umple/dist/qa

BUILD FAILED
/home/yiran/program/Umple/umple/build/build.xml:9: /home/yiran/program/Umple/umple/build/build.xml:14: The following error occurred while executing this line:
/home/yiran/program/Umple/umple/build/build.sandbox.xml:59: The following error occurred while executing this line:
/home/yiran/program/Umple/umple/build/build.sandbox.xml:24: Java returned: 1

Total time: 0 seconds

Contributor

YiranShu commented Oct 7, 2018

@TimLethbridge
I pulled the branch Java11AndIssue1176. The full build fails immediately after I launch a full build. So I cannot see the 6 failing cases you mentioned. Following is the failure message I encountered.
yiran@yiran-virtual-machine:~/program/Umple/umple/build$ ant -Dmyenv=local
Buildfile: /home/yiran/program/Umple/umple/build/build.xml
[echo] Using myenv=local
[echo] Last Version: 1.29.1.4260.b21abf3a3

build:
[echo] Using myenv=local
[echo] Last Version: 1.29.1.4260.b21abf3a3

qaBuildingPage:
[echo] Starting Build
[copy] Copying 1 file to /home/yiran/program/Umple/umple/dist/qa
[echo] Building Sandbox for Testing Infrastructure
[echo] Using myenv=local
[echo] Last Version: 1.29.1.4260.b21abf3a3

build:
[echo] A sample build file for the Sandbox
[echo] Using myenv=local
[echo] Last Version: 1.29.1.4260.b21abf3a3

template.clean:
[delete] Deleting directory /home/yiran/program/Umple/umple/cruise.umple.validator/bin
[delete] Deleting directory /home/yiran/program/Umple/umple/cruise.umplificator/bin
[delete] Deleting directory /home/yiran/program/Umple/umple/sandbox/bin
[delete] Deleting directory /home/yiran/program/Umple/umple/dist/sandbox
[echo] Using myenv=local
[echo] Last Version: 1.29.1.4260.b21abf3a3

template.init:
[mkdir] Created dir: /home/yiran/program/Umple/umple/cruise.umple.validator/bin
[mkdir] Created dir: /home/yiran/program/Umple/umple/cruise.umplificator/bin
[mkdir] Created dir: /home/yiran/program/Umple/umple/sandbox/bin
[mkdir] Created dir: /home/yiran/program/Umple/umple/dist/sandbox
[echo] Using myenv=local
[echo] Last Version: 1.29.1.4260.b21abf3a3

umpleSandbox:
[java] Error: Unable to access jarfile /home/yiran/program/Umple/umple/dist/libs/umple-1.29.1.4260.b21abf3a3.jar
[echo] Using myenv=local
[echo] Last Version: 1.29.1.4260.b21abf3a3

qaLandingPage:
[echo] Creating a QA Landing Page
[copy] Copying 1 file to /home/yiran/program/Umple/umple/dist/qa

BUILD FAILED
/home/yiran/program/Umple/umple/build/build.xml:9: /home/yiran/program/Umple/umple/build/build.xml:14: The following error occurred while executing this line:
/home/yiran/program/Umple/umple/build/build.sandbox.xml:59: The following error occurred while executing this line:
/home/yiran/program/Umple/umple/build/build.sandbox.xml:24: Java returned: 1

Total time: 0 seconds

@TimLethbridge

This comment has been minimized.

Show comment
Hide comment
@TimLethbridge

TimLethbridge Oct 10, 2018

Member

I am going to merge PR #1387 off branch Java11AndIssue1176 so please start a new branch for further work on this. Umple needs to compile properly under Java 11.

Member

TimLethbridge commented Oct 10, 2018

I am going to merge PR #1387 off branch Java11AndIssue1176 so please start a new branch for further work on this. Umple needs to compile properly under Java 11.

TimLethbridge added a commit that referenced this issue Oct 10, 2018

Debugging automation moved this from To do to Done Oct 10, 2018

@TimLethbridge TimLethbridge reopened this Oct 10, 2018

Debugging automation moved this from Done to To do Oct 10, 2018

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