Search in sources :

Example 1 with GapicTestConfig

use of com.google.api.codegen.gapic.GapicTestConfig in project toolkit by googleapis.

the class CodegenTestUtil method readModel.

public static Model readModel(TestDataLocator locator, TemporaryFolder tempDir, String[] protoFiles, String[] yamlFiles) {
    TestConfig testConfig = new GapicTestConfig(locator, tempDir.getRoot().getPath(), Arrays.asList(protoFiles));
    Model model = testConfig.createModel(Arrays.asList(yamlFiles));
    StandardSetup.registerStandardProcessors(model);
    StandardSetup.registerStandardConfigAspects(model);
    model.establishStage(Merged.KEY);
    return model;
}
Also used : GapicTestConfig(com.google.api.codegen.gapic.GapicTestConfig) TestConfig(com.google.api.tools.framework.model.testing.TestConfig) GapicTestConfig(com.google.api.codegen.gapic.GapicTestConfig) Model(com.google.api.tools.framework.model.Model)

Aggregations

GapicTestConfig (com.google.api.codegen.gapic.GapicTestConfig)1 Model (com.google.api.tools.framework.model.Model)1 TestConfig (com.google.api.tools.framework.model.testing.TestConfig)1