-
Bug
-
Resolution: Duplicate
-
Major
-
None
-
Platform: All, OS: Linux
When building an UCM project (snapshot view) it fails due to lshistory being run
from the wrong directory.
The snapshot view is created with paths according to this pattern:
.../workspace/view/vob/component
The lshistory command is run from within the workspace directory, however the
arguments are provided as if it was running from the view directory.
Patching UcmChangeLogAction.java so that it conforms to the following unit test
solves the problem for me (but i guess it works differently on other
platforms?). I suppose the proper solution would be to run lshistory from the
view directory instead?
@Test
public void assertParsingOfNonIntegrationActivity() throws Exception {
context.checking(new Expectations() {
{
one(cleartool).lshistory(with(any(String.class)),
with(aNull(Date.class)),
with(equal("view")), with(equal("Release_2_1_int")),
with(equal(new String[]
)));
will(returnValue(new StringReader(
"\"20080509.140451\" " +
"\"view/vobs/projects/Server//config-admin-client\" " +
"\"/main/Product/Release_3_3_int/Release_3_3_jdk5/2\" " +
"\"Release_3_3_jdk5.20080509.155359\" " +
"\"create directory version\" " +
"\"checkin\" \"username\" ")));
one(cleartool).lsactivity(
with(equal("Release_3_3_jdk5.20080509.155359")),
with(aNonNull(String.class)),with(aNonNull(String.class)));
will(returnValue(new StringReader("\"Convert to Java 6\" " +
"\"Release_3_3_jdk5\" " +
"\"bob\" ")));
}
});
UcmChangeLogAction action = new UcmChangeLogAction(cleartool,null);
List<UcmActivity> activities = action.getChanges(null, "view", new
String[]
, new Stri
ng[]
);
assertEquals("There should be 1 activity", 1, activities.size());
UcmActivity activity = activities.get(0);
assertEquals("Activity name is incorrect",
"Release_3_3_jdk5.20080509.155359", activity.getName());
assertEquals("Activity headline is incorrect", "Convert to Java 6",
activity.getHeadline());
assertEquals("Activity stream is incorrect", "Release_3_3_jdk5",
activity.getStream());
assertEquals("Activity user is incorrect", "bob", activity.getUser());
}
- duplicates
-
JENKINS-3097 UCM build fails when using multiple vobs
- Closed