mirror of
https://github.com/Kingsrook/qqq.git
synced 2025-07-21 14:38:43 +00:00
Implementation of QContext everywhere, instead of passing QInstance and QSession in all ActionInputs
This commit is contained in:
@ -33,12 +33,15 @@ import java.util.Arrays;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.UUID;
|
||||
import com.kingsrook.qqq.backend.core.context.QContext;
|
||||
import com.kingsrook.qqq.backend.core.model.metadata.QInstance;
|
||||
import com.kingsrook.qqq.backend.core.model.session.QSession;
|
||||
import com.kingsrook.qqq.backend.core.utils.JsonUtils;
|
||||
import com.kingsrook.qqq.backend.core.utils.StringUtils;
|
||||
import org.apache.commons.io.FileUtils;
|
||||
import org.json.JSONArray;
|
||||
import org.json.JSONObject;
|
||||
import org.junit.jupiter.api.AfterEach;
|
||||
import org.junit.jupiter.api.BeforeEach;
|
||||
import org.junit.jupiter.api.Disabled;
|
||||
import org.junit.jupiter.api.Test;
|
||||
@ -68,6 +71,18 @@ class QPicoCliImplementationTest
|
||||
public void beforeEach() throws Exception
|
||||
{
|
||||
TestUtils.primeTestDatabase();
|
||||
QContext.init(TestUtils.defineInstance(), new QSession());
|
||||
}
|
||||
|
||||
|
||||
|
||||
/*******************************************************************************
|
||||
**
|
||||
*******************************************************************************/
|
||||
@AfterEach
|
||||
void afterEach()
|
||||
{
|
||||
QContext.clear();
|
||||
}
|
||||
|
||||
|
||||
@ -910,7 +925,7 @@ class QPicoCliImplementationTest
|
||||
*******************************************************************************/
|
||||
private TestOutput testCli(String... args)
|
||||
{
|
||||
QInstance qInstance = TestUtils.defineInstance();
|
||||
QInstance qInstance = QContext.getQInstance();
|
||||
return testCli(qInstance, args);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user