From 51b40782884ce281de91200a86339432c0311dbf Mon Sep 17 00:00:00 2001 From: Anuken Date: Thu, 3 Dec 2020 11:05:02 -0500 Subject: [PATCH] Clean tests before running --- .github/workflows/push.yml | 2 +- core/src/mindustry/world/blocks/distribution/Conveyor.java | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index 56d3fe6dd7..07ae6b09ab 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -13,7 +13,7 @@ jobs: with: java-version: 14 - name: Run unit tests - run: ./gradlew test + run: ./gradlew clean cleanTest test - name: Trigger BE build if: ${{ github.repository == 'Anuken/Mindustry' }} run: | diff --git a/core/src/mindustry/world/blocks/distribution/Conveyor.java b/core/src/mindustry/world/blocks/distribution/Conveyor.java index 23fa7a2a46..ab6f394afd 100644 --- a/core/src/mindustry/world/blocks/distribution/Conveyor.java +++ b/core/src/mindustry/world/blocks/distribution/Conveyor.java @@ -255,7 +255,7 @@ public class Conveyor extends Block implements Autotiler{ } public boolean pass(Item item){ - if(next != null && next.team == team && next.acceptItem(this, item)){ + if(item != null && next != null && next.team == team && next.acceptItem(this, item)){ next.handleItem(this, item); return true; }