https://pantsbuild.org/ logo
#general
Title
# general
f

faint-dress-64989

02/01/2023, 12:07 AM
I'm the process of migrating some unit test for a
pyspark
application over to our pants repo. Previously, I was running these test inside a docker image built with the databricks runtime as their base image. Java exists on said image as it is a dependency of spark and thus databricks. Now the following fixture no longer works as Java isn't install on my machine:
Copy code
@pytest.fixture(scope="session")
def spark_session() -> SparkSession:
    return (
        SparkSession.builder.master("local")
        .appName("spark session example")
        .getOrCreate()
    )
Is there a way for pants to manage the setup/installation of java for this test suite?
4 Views