def METHOD_NAME(self):
    test_path = "./tests/test_configs/spark_job/spark_job_test.yml"
    with open("./tests/test_configs/spark_job/spark_job_rest.json", "r") as f:
        target = yaml.safe_load(f)
    with open(test_path, "r") as f:
        cfg = yaml.safe_load(f)
        context = {BASE_PATH_CONTEXT_KEY: Path(test_path).parent}
        schema = SparkJobSchema(context=context)
        internal_representation: SparkJob = SparkJob(**schema.load(cfg))
    source = internal_representation._to_rest_object()
    assert source.name == target["name"]
    assert source.properties.conf == target["conf"]
    assert source.properties.code_id == target["code"]