Skip to content

Commit

Permalink
Fix plugin not failing if post error
Browse files Browse the repository at this point in the history
  • Loading branch information
bensofficial committed Aug 16, 2023
1 parent 4d40a44 commit 3126b49
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: '8'
java-version: '17'
cache: 'gradle'
- name: Production Build
run: ./gradlew clean jar
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
import com.google.gson.Gson;
import de.tum.cit.ase.artemis_notification_plugin.configuration.Context;
import de.tum.cit.ase.artemis_notification_plugin.configuration.ContextFactory;
import de.tum.cit.ase.artemis_notification_plugin.exception.PostResultException;
import de.tum.cit.ase.artemis_notification_plugin.exception.TestParsingException;
import de.tum.cit.ase.artemis_notification_plugin.model.Commit;
import de.tum.cit.ase.artemis_notification_plugin.model.TestResults;
Expand Down Expand Up @@ -91,6 +92,7 @@ public void postResult(TestResults results, Context context) {
}
catch (HttpException | IOException e) {
LOGGER.error(e.getMessage(), e);
throw new PostResultException(e);
}
}

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
package de.tum.cit.ase.artemis_notification_plugin.exception;

public class PostResultException extends RuntimeException {

public PostResultException(Throwable cause) {
super(cause);
}
}

0 comments on commit 3126b49

Please sign in to comment.