Android Extensions: Support LayoutContainer in code generation

This commit is contained in:
Yan Zhulanow
2017-06-05 22:46:37 +03:00
parent a69f9729e0
commit 423a09e46a
32 changed files with 279 additions and 56 deletions
@@ -321,10 +321,7 @@ public abstract class CodegenTestCase extends KtUsefulTestCase {
@NotNull
protected String relativePath(@NotNull File file) {
String stringToCut = codegenTestBasePath();
String systemIndependentPath = file.getPath().replace(File.separatorChar, '/');
assert systemIndependentPath.startsWith(stringToCut) : "File path is not absolute: " + file;
return systemIndependentPath.substring(stringToCut.length());
return FilesKt.toRelativeString(file.getAbsoluteFile(), new File(codegenTestBasePath()).getAbsoluteFile());
}
@NotNull