mirror of
https://github.com/ebean-orm/ebean.git
synced 2024-04-21 10:51:47 +00:00
initial add of EbeanORM server based on v2.8.1
This commit is contained in:
@@ -0,0 +1,28 @@
|
||||
|
||||
package com.avaje.tests.unitinternal;
|
||||
|
||||
import junit.framework.Assert;
|
||||
import junit.framework.TestCase;
|
||||
|
||||
|
||||
public class TestBasics extends TestCase {
|
||||
|
||||
|
||||
private String parentPath(String path) {
|
||||
|
||||
int pos = path.lastIndexOf('.');
|
||||
if (pos == -1){
|
||||
return null;
|
||||
} else {
|
||||
return path.substring(0, pos);
|
||||
}
|
||||
}
|
||||
|
||||
public void testParentPath() {
|
||||
|
||||
Assert.assertTrue((parentPath("banana") == null));
|
||||
Assert.assertTrue((parentPath("banana.apple").equals("banana")));
|
||||
Assert.assertTrue((parentPath("banana.apple.o").equals("banana.apple")));
|
||||
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user