-
Notifications
You must be signed in to change notification settings - Fork 28
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix for test template preview and execute
- Loading branch information
Showing
3 changed files
with
36 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
30 changes: 21 additions & 9 deletions
30
...c/main/java/webhook/teamcity/server/rest/jersey/WebHookUserRequestedExecutorProvider.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,30 @@ | ||
package webhook.teamcity.server.rest.jersey; | ||
|
||
import javax.ws.rs.ext.Provider; | ||
|
||
import org.springframework.stereotype.Service; | ||
import org.springframework.context.annotation.Bean; | ||
import org.springframework.context.annotation.Configuration; | ||
import org.springframework.stereotype.Component; | ||
|
||
import jetbrains.buildServer.server.rest.jersey.provider.annotated.JerseyInjectableBeanProvider; | ||
import webhook.teamcity.testing.WebHookUserRequestedExecutor; | ||
|
||
@Service | ||
@SuppressWarnings("squid:S1191") | ||
@Component | ||
@Configuration | ||
public class WebHookUserRequestedExecutorProvider implements JerseyInjectableBeanProvider { | ||
|
||
private final WebHookUserRequestedExecutor myExecutor; | ||
|
||
public WebHookUserRequestedExecutorProvider(WebHookUserRequestedExecutor executor) { | ||
myExecutor = executor; | ||
} | ||
|
||
@Bean | ||
public WebHookUserRequestedExecutor getBean() { | ||
return this.myExecutor; | ||
} | ||
|
||
@Override | ||
public Class<?> getBeanClass() { | ||
return WebHookUserRequestedExecutor.class; | ||
} | ||
|
||
@Override | ||
public Class<?> getBeanClass() { | ||
return WebHookUserRequestedExecutor.class; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters