[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
Re: [egit-dev] SWTBot tests
|
I've updated the patch to only contain
the elimination of the file handle leaks I could see. I'm giving
up on fixing the random failure corresponding to the "remote"
configuration of test repositories.
The "suspicious" line I was talking about was to fix a random
failure of
org.eclipse.egit.ui.view.repositories.GitRepositoriesViewFetchAndPushTest.
On windows, it *sometimes* fails right within the "beforeClass",
when it tries to create its remote configuration. I tracked that
down all the way to
org.eclipse.jgit.storage.file.FileBasedConfig.save(). In that
particular occurence, the base config is not updated by the call
to save.
In short, if you do the following and add a breakpoint on the
"System.out" line, it will sometimes be triggered (more likely
when launching the full swtbot suite).
diff --git
a/org.eclipse.jgit/src/org/eclipse/jgit/storage/file/FileBasedConfig.java
b/org.eclipse.jgit/src/org/eclipse/jgit/storage/file/FileBasedConfig.java
index 5509fc6..5860cbe 100644
---
a/org.eclipse.jgit/src/org/eclipse/jgit/storage/file/FileBasedConfig.java
+++
b/org.eclipse.jgit/src/org/eclipse/jgit/storage/file/FileBasedConfig.java
@@ -213,6 +213,8 @@ public void save() throws IOException {
}
snapshot = lf.getCommitSnapshot();
hash = hash(out);
+ if (text.length() != 0 && toText().length() == 0)
+ System.out.println("?");
// notify the listeners
fireConfigChangedEvent();
}
Basically: we had some text (the full config file's content), we
saved it... and afterwards we no longer have anything in the
config *object*. The config *file* on disk is fine and contains
the correct, saved content ... only the object seems to have been
wiped out.
Laurent
On 22/03/2013 11:34, Laurent Goubet wrote:
With all changes from https://git.eclipse.org/r/#/c/11381/
, I only have a single test that remains as failing, though I
have no idea whether this is a windows-specific failure or not.
org.eclipse.egit.ui.test.team.actions.MergeToolTest.useHeadOptionShouldCauseFileToNotHaveConflictMarkers()
Also... one of the changes seem very strange to me :
https://git.eclipse.org/r/#/c/11381/1/org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/view/repositories/GitRepositoriesViewTestBase.java
The "createRemoteRepository" method of that class was failing
every run, telling me that the remote "push" did not exist.
Using git on the command line returned a similar result with
this test repository. Basically, as long as a "remote" only add
a "pushurl" and no "url", it was not recognized as a real
"remote" ... Maybe the solution I used here (setting a "url" on
the remote) is not correct and there's a bug deeper down?
Laurent
On 21/03/2013 22:38, Matthias Sohn wrote:
_______________________________________________
egit-dev mailing list
egit-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/egit-dev
|
begin:vcard
fn:Laurent Goubet
n:Goubet;Laurent
org:<a href="http://www.obeo.fr">Obeo</a>
email;internet:laurent.goubet@xxxxxxx
url:http://www.obeo.fr
version:2.1
end:vcard