[Git] IDEA-59587 again. Moved New files are marked as not changed.
authorKirill Likhodedov <kirill.likhodedov@jetbrains.com>
Fri, 13 May 2011 14:14:55 +0000 (18:14 +0400)
committerKirill Likhodedov <kirill.likhodedov@jetbrains.com>
Fri, 13 May 2011 14:25:58 +0000 (18:25 +0400)
commitde3ff0576939ffc4412e0228dd6103825cdd2a73
treef9d3000592a7653b69482acc7a19a21b41c6de8c
parent5b532b3e2f46ae267e07e44ed5dd232e318da18e
[Git] IDEA-59587 again. Moved New files are marked as not changed.

Root cause: comparing VirtualFiles when identifying who is the ancestor, while VirtualFile has changed due to the file move.
1. Don't work with FilePaths - instead compare paths as Strings sorted lexicographically. This might leave extra paths, but it's faster.
2. Add a test for the bug.

[Reviewed by Max]
plugins/git4idea/src/git4idea/changes/ChangeCollector.java
plugins/git4idea/tests/git4idea/tests/GitChangeProviderTest.java