mirror of
https://github.com/dbeaver/cloudbeaver.git
synced 2026-09-24 16:04:36 +08:00
Tests fix (windows crlf)
This commit is contained in:
+8
-2
@@ -27,6 +27,7 @@ import org.jkiss.dbeaver.model.impl.sql.BasicSQLDialect;
|
||||
import org.jkiss.dbeaver.model.sql.SQLDialect;
|
||||
import org.jkiss.dbeaver.model.sql.translate.SQLQueryTranslator;
|
||||
import org.jkiss.dbeaver.runtime.DBWorkbench;
|
||||
import org.jkiss.dbeaver.utils.GeneralUtils;
|
||||
import org.junit.Assert;
|
||||
import org.junit.Test;
|
||||
|
||||
@@ -191,10 +192,15 @@ public class SQLQueryTranslatorTest {
|
||||
);
|
||||
Assert.assertEquals(
|
||||
entry.getKey().getDialectId() + " has invalid syntax " + translated,
|
||||
entry.getValue().toLowerCase(),
|
||||
translated.toLowerCase()
|
||||
normalizeScript(entry.getValue()),
|
||||
normalizeScript(translated)
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
private static String normalizeScript(String script) {
|
||||
// Unify for tests
|
||||
return script.toLowerCase().replace(GeneralUtils.getDefaultLineSeparator(), "\n");
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user