Merge lp:~zorba-coders/zorba/fix-shebang-test into lp:zorba

Proposed by Chris Hillery
Status: Merged
Approved by: Sorin Marian Nasoi
Approved revision: 11422
Merged at revision: 11423
Proposed branch: lp:~zorba-coders/zorba/fix-shebang-test
Merge into: lp:zorba
Diff against target: 24 lines (+4/-4)
2 files modified
bin/CMakeLists.txt (+3/-3)
bin/test/shebang.xq (+1/-1)
To merge this branch: bzr merge lp:~zorba-coders/zorba/fix-shebang-test
Reviewer Review Type Date Requested Status
Sorin Marian Nasoi Approve
Chris Hillery Approve
Review via email: mp+161785@code.launchpad.net

Commit message

Don't use absolute path for shebang test - can be too long on RQ.

To post a comment you must log in.
Revision history for this message
Chris Hillery (ceejatec) wrote :

The issue was that previously, shebang.xq was created with an absolute path to the Zorba interpreter. However, on the RQ, the branch name is used as part of the directory path, and this led to some very long absolute paths. Apparently there is a limit of 64 characters for the shebang line on the RQ machine. The merge which added this test had a short name so it worked; later merges were not so lucky.

Now I just use a relative path for the shebang file, and set WORKING_DIRECTORY for the test so it will be in the right place.

Revision history for this message
Chris Hillery (ceejatec) :
review: Approve
Revision history for this message
Sorin Marian Nasoi (sorin.marian.nasoi) :
review: Approve
Revision history for this message
Zorba Build Bot (zorba-buildbot) wrote :
Revision history for this message
Zorba Build Bot (zorba-buildbot) wrote :

Validation queue job fix-shebang-test-2013-05-01T14-58-44.509Z is finished. The final status was:

All tests succeeded!

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'bin/CMakeLists.txt'
2--- bin/CMakeLists.txt 2013-05-01 03:14:44 +0000
3+++ bin/CMakeLists.txt 2013-05-01 07:01:25 +0000
4@@ -80,9 +80,9 @@
5 ZORBA_SET_TEST_PROPERTY(bin/zorba5 PASS_REGULAR_EXPRESSION ".*No queries submitted.*")
6
7 IF (UNIX)
8- CONFIGURE_FILE ("${CMAKE_CURRENT_SOURCE_DIR}/test/shebang.xq.in"
9- "${CMAKE_CURRENT_BINARY_DIR}/shebang.xq" @ONLY)
10- ADD_TEST (bin/shebang "${CMAKE_CURRENT_BINARY_DIR}/shebang.xq")
11+ ADD_TEST (NAME bin/shebang
12+ COMMAND "${CMAKE_CURRENT_SOURCE_DIR}/test/shebang.xq"
13+ WORKING_DIRECTORY "${CMAKE_BINARY_DIR}")
14 SET_TESTS_PROPERTIES (bin/shebang PROPERTIES PASS_REGULAR_EXPRESSION "shebang success")
15 ENDIF (UNIX)
16
17
18=== renamed file 'bin/test/shebang.xq.in' => 'bin/test/shebang.xq'
19--- bin/test/shebang.xq.in 2013-05-01 03:14:44 +0000
20+++ bin/test/shebang.xq 2013-05-01 07:01:25 +0000
21@@ -1,2 +1,2 @@
22-#!@ZORBA_EXE@
23+#!bin/zorba
24 "shebang success"

Subscribers

People subscribed via source and target branches