def test_class_buoyancy_should_set_density_for_valid_number():
    b = Buoyancy()

    b.density = 1100.0

    assert 1100.0 == b.density
def test_class_buoyancy_density_setter_should_fail_for_non_numeric():
    b = Buoyancy()

    with pytest.raises(ValueError):
        b.density = 'a'