mirror of
https://github.com/ebean-orm/ebean.git
synced 2024-04-21 10:51:47 +00:00
#1658 - ENH: Add label to ProfileLocation and use as default query label
This commit is contained in:
@@ -15,6 +15,8 @@ public class BasicProfileLocationTest {
|
||||
|
||||
assertThat(loc.obtain()).endsWith(":12)");
|
||||
assertThat(loc.shortDescription()).isEqualTo("NativeMethodAccessorImpl.invoke0(Native Method:12)");
|
||||
assertThat(loc.label()).isEqualTo("NativeMethodAccessorImpl.invoke0");
|
||||
|
||||
}
|
||||
|
||||
@Test
|
||||
@@ -23,6 +25,7 @@ public class BasicProfileLocationTest {
|
||||
BasicProfileLocation loc = new BasicProfileLocation("com.foo.Bar.all");
|
||||
assertThat(loc.obtain()).isEqualTo("com.foo.Bar.all");
|
||||
assertThat(loc.shortDescription()).isEqualTo("Bar.all");
|
||||
assertThat(loc.label()).isEqualTo("Bar.all");
|
||||
}
|
||||
|
||||
@Test
|
||||
@@ -31,5 +34,6 @@ public class BasicProfileLocationTest {
|
||||
BasicProfileLocation loc = new BasicProfileLocation("foo.Bar.all");
|
||||
assertThat(loc.obtain()).isEqualTo("foo.Bar.all");
|
||||
assertThat(loc.shortDescription()).isEqualTo("Bar.all");
|
||||
assertThat(loc.label()).isEqualTo("Bar.all");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -17,6 +17,8 @@ public class ProfileLocationTest {
|
||||
public void test_obtain() {
|
||||
|
||||
assertThat(doIt()).isEqualTo("org.tests.profile.ProfileLocationTest.doIt(ProfileLocationTest.java:13)");
|
||||
assertThat(loc.shortDescription()).isEqualTo("ProfileLocationTest.doIt(ProfileLocationTest.java:13)");
|
||||
assertThat(loc.label()).isEqualTo("ProfileLocationTest.doIt");
|
||||
}
|
||||
|
||||
@Test
|
||||
|
||||
Reference in New Issue
Block a user