Skip to content

Commit

Permalink
add and skip problematic test for car emission factor
Browse files Browse the repository at this point in the history
  • Loading branch information
han16nah committed May 5, 2024
1 parent ae72bbb commit 23e0d16
Showing 1 changed file with 16 additions and 2 deletions.
18 changes: 16 additions & 2 deletions tests/unit/test_parameters.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
PlaneEmissionParameters,
HeatingEmissionParameters,
ElectricityEmissionParameters,
CarEmissionParameters,
)
import pytest
from pydantic import ValidationError
Expand Down Expand Up @@ -58,5 +59,18 @@ def test_emission_factors_electricity(emission_factors_test) -> None:
assert co2e == co2e_expected


def test_emission_factors_bus():
pass
@pytest.mark.skip(
reason="No emission factor available, if defaults are used in combination with this user input"
"We first need to decide how to handle this"
)
def test_emission_factors_car(emission_factors_test) -> None:
"""Test emission factors for car"""
size = "small"
co2e_expected = 0.1

params = CarEmissionParameters(size=size)

# Get the co2 factor
co2e = emission_factors_test.get(params.dict())

assert co2e == co2e_expected

0 comments on commit 23e0d16

Please sign in to comment.