mirror of
https://github.com/ebean-orm/ebean.git
synced 2026-11-12 06:39:59 +00:00
Remove unused ServerConfig debugSql options, Update Tests to use agentloader
This commit is contained in:
1 parent
bb2479c9e7
commit
2f97c5c36e
217 files changed
+6351
-6740
No files matched your search
@@ -2,32 +2,31 @@ package com.avaje.tests.text.json;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import junit.framework.TestCase;
|
||||
import org.junit.Test;
|
||||
|
||||
import com.avaje.ebean.BaseTestCase;
|
||||
import com.avaje.ebean.Ebean;
|
||||
import com.avaje.ebean.text.json.JsonContext;
|
||||
import com.avaje.ebean.text.json.JsonWriteOptions;
|
||||
import com.avaje.tests.model.basic.Customer;
|
||||
import com.avaje.tests.model.basic.ResetBasicData;
|
||||
|
||||
public class TestTextJsonInvokeLazy extends TestCase {
|
||||
public class TestTextJsonInvokeLazy extends BaseTestCase {
|
||||
|
||||
public void test() {
|
||||
|
||||
ResetBasicData.reset();
|
||||
|
||||
List<Customer> list = Ebean.find(Customer.class)
|
||||
.select("name")
|
||||
.findList();
|
||||
|
||||
JsonWriteOptions opt = new JsonWriteOptions();
|
||||
opt.setRootPathProperties("name, status");
|
||||
|
||||
JsonContext jsonContext = Ebean.createJsonContext();
|
||||
String jsonString = jsonContext.toJsonString(list, true, opt);
|
||||
|
||||
System.out.println(jsonString);
|
||||
|
||||
|
||||
}
|
||||
@Test
|
||||
public void test() {
|
||||
|
||||
ResetBasicData.reset();
|
||||
|
||||
List<Customer> list = Ebean.find(Customer.class).select("name").findList();
|
||||
|
||||
JsonWriteOptions opt = new JsonWriteOptions();
|
||||
opt.setRootPathProperties("name, status");
|
||||
|
||||
JsonContext jsonContext = Ebean.createJsonContext();
|
||||
String jsonString = jsonContext.toJsonString(list, true, opt);
|
||||
|
||||
System.out.println(jsonString);
|
||||
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user