aboutsummaryrefslogtreecommitdiffstats
path: root/tests/plugins/server-plugin/src
diff options
context:
space:
mode:
authorSimon Brandhof <simon.brandhof@sonarsource.com>2017-08-28 16:52:58 +0200
committerSébastien Lesaint <sebastien.lesaint@sonarsource.com>2017-09-13 15:50:48 +0200
commit1c95f883c3ffee922a56ad3431e2b07a2378488e (patch)
treea495d0962e04a69635504ae11e9379e9aa83c412 /tests/plugins/server-plugin/src
parentd42dbb96cbcefb6f631fc9ddb52ec8755e26f19e (diff)
downloadsonarqube-1c95f883c3ffee922a56ad3431e2b07a2378488e.tar.gz
sonarqube-1c95f883c3ffee922a56ad3431e2b07a2378488e.zip
SONAR-9739 make StartupCrash startable
Diffstat (limited to 'tests/plugins/server-plugin/src')
-rw-r--r--tests/plugins/server-plugin/src/main/java/StartupCrash.java8
1 files changed, 5 insertions, 3 deletions
diff --git a/tests/plugins/server-plugin/src/main/java/StartupCrash.java b/tests/plugins/server-plugin/src/main/java/StartupCrash.java
index cf57ccbc653..3e55bab80b9 100644
--- a/tests/plugins/server-plugin/src/main/java/StartupCrash.java
+++ b/tests/plugins/server-plugin/src/main/java/StartupCrash.java
@@ -17,12 +17,12 @@
* along with this program; if not, write to the Free Software Foundation,
* Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/
+import org.sonar.api.Startable;
import org.sonar.api.config.Settings;
import org.sonar.api.server.ServerSide;
-
@ServerSide
-public class StartupCrash {
+public class StartupCrash implements Startable {
private final Settings settings;
@@ -30,13 +30,15 @@ public class StartupCrash {
this.settings = settings;
}
+ @Override
public void start() {
if (settings.getBoolean("failAtStartup")) {
throw new IllegalStateException("Error in plugin [server]");
}
}
+ @Override
public void stop() {
-
+ // do nothing
}
}