summaryrefslogtreecommitdiff
path: root/patchwork/tests/test_fields.py
blob: 577b7b238476f459cc0f0a0861c5b1b20ae8b030 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
# Patchwork - automated patch tracking system
# Copyright (C) 2016 Intel Corporation
#
# SPDX-License-Identifier: GPL-2.0-or-later

from django.test import SimpleTestCase

from patchwork import fields


class TestHashField(SimpleTestCase):

    def test_n_bytes(self):
        """Sanity check the hashing algorithm.

        Changing this can change our database schema.
        """
        field = fields.HashField()
        self.assertEqual(field.n_bytes, 40)