aboutsummaryrefslogtreecommitdiff
path: root/test/java/spark/run-tests.sh
diff options
context:
space:
mode:
Diffstat (limited to 'test/java/spark/run-tests.sh')
-rwxr-xr-xtest/java/spark/run-tests.sh46
1 files changed, 46 insertions, 0 deletions
diff --git a/test/java/spark/run-tests.sh b/test/java/spark/run-tests.sh
new file mode 100755
index 000000000..f637c8c59
--- /dev/null
+++ b/test/java/spark/run-tests.sh
@@ -0,0 +1,46 @@
+#!/bin/bash
+
+set -e
+
+echo "=== SeaweedFS Spark Integration Tests Runner ==="
+echo ""
+
+# Check if SeaweedFS is running
+check_seaweedfs() {
+ if curl -f http://localhost:8888/ > /dev/null 2>&1; then
+ echo "✓ SeaweedFS filer is accessible at http://localhost:8888"
+ return 0
+ else
+ echo "✗ SeaweedFS filer is not accessible"
+ return 1
+ fi
+}
+
+# Main
+if ! check_seaweedfs; then
+ echo ""
+ echo "Please start SeaweedFS first. You can use:"
+ echo " cd test/java/spark && docker-compose up -d"
+ echo "Or:"
+ echo " make docker-up"
+ exit 1
+fi
+
+echo ""
+echo "Running Spark integration tests..."
+echo ""
+
+export SEAWEEDFS_TEST_ENABLED=true
+export SEAWEEDFS_FILER_HOST=localhost
+export SEAWEEDFS_FILER_PORT=8888
+export SEAWEEDFS_FILER_GRPC_PORT=18888
+
+# Run tests
+mvn test "$@"
+
+echo ""
+echo "✓ Test run completed"
+echo "View detailed reports in: target/surefire-reports/"
+
+
+