Пример #1
0
def test_ideal_air_lockability():
    """Test the lockability of IdealAirSystem objects."""
    ideal_air = IdealAirSystem()

    ideal_air.sensible_heat_recovery = 0.6
    ideal_air.lock()
    with pytest.raises(AttributeError):
        ideal_air.sensible_heat_recovery = 0.75
    ideal_air.unlock()
    ideal_air.sensible_heat_recovery = 0.75
Пример #2
0
def test_ideal_air_system_setability():
    """Test the setting of properties of IdealAirSystem."""
    ideal_air = IdealAirSystem()

    ideal_air.heating_limit = 1000
    assert ideal_air.heating_limit == 1000
    ideal_air.cooling_limit = 2000
    assert ideal_air.cooling_limit == 2000
    ideal_air.economizer_type = 'DifferentialEnthalpy'
    assert ideal_air.economizer_type == 'DifferentialEnthalpy'
    ideal_air.sensible_heat_recovery = 0.75
    assert ideal_air.sensible_heat_recovery == 0.75
    ideal_air.latent_heat_recovery = 0.65
    assert ideal_air.latent_heat_recovery == 0.65