def METHOD_NAME(config, is_valid, db, app, setup_dummy_sensors):
    schema = ProfitOrLossReporterConfigSchema()
    if is_valid:
        schema.load(config)
    else:
        with pytest.raises(ValidationError):
            schema.load(config)