def test_shorter_than():
    assert hug.types.shorter_than(10)('hi there') == 'hi there'
    assert hug.types.shorter_than(10)(1) == '1'
    assert hug.types.shorter_than(10)('') == ''
    assert '10' in hug.types.shorter_than(10).__doc__
    with pytest.raises(ValueError):
        assert hug.types.shorter_than(10)('there is quite a bit of text here, in fact way more than allowed')
Tests that hug's shorter than type successfully limits the values passed in
dataset/ETHPy150Open timothycrosley/hug/tests/test_types.py/test_shorter_than