コード例 #1
0
ファイル: __init__.py プロジェクト: vitalk/flask-staticutils
def nonexisting_file_checksum():
    assert checksum('nosuchfile', 10) is None
コード例 #2
0
ファイル: __init__.py プロジェクト: vitalk/flask-staticutils
def existing_file_checksum():
    path = os.path.join(os.getcwd(), 'requirements.dev.txt')
    must_be = '0cef80c690b7529d44b332fc'
    h = checksum(path, 24)
    assert h == must_be
    assert len(h) <= 24