Initial harness for conditionals live hover tests
This commit is contained in:
@@ -0,0 +1,33 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2017 Pivotal, Inc.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* Pivotal, Inc. - initial API and implementation
|
||||
*******************************************************************************/
|
||||
package org.springframework.ide.vscode.boot.java.conditionals.test;
|
||||
|
||||
import org.junit.Before;
|
||||
import org.springframework.ide.vscode.boot.java.BootJavaLanguageServer;
|
||||
import org.springframework.ide.vscode.languageserver.testharness.LanguageServerHarness;
|
||||
import org.springframework.ide.vscode.project.harness.BootLanguageServerHarness;
|
||||
import org.springframework.ide.vscode.project.harness.MockRunningAppProvider;
|
||||
|
||||
public class ConditionalsLiveHoverTest {
|
||||
|
||||
private LanguageServerHarness<BootJavaLanguageServer> harness;
|
||||
private MockRunningAppProvider mockAppProvider;
|
||||
|
||||
@Before
|
||||
public void setup() throws Exception {
|
||||
|
||||
mockAppProvider = new MockRunningAppProvider();
|
||||
harness = BootLanguageServerHarness.builder()
|
||||
.runningAppProvider(mockAppProvider.provider)
|
||||
.build();
|
||||
}
|
||||
|
||||
}
|
||||
@@ -105,6 +105,11 @@ public class MockRunningAppProvider {
|
||||
return this;
|
||||
}
|
||||
|
||||
public MockAppBuilder getAutoConfigReport(String autoConfigReport) throws Exception {
|
||||
when(app.getAutoConfigReport()).thenReturn(autoConfigReport);
|
||||
return this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Builds the mock app and adds it to the app provider
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user