Skip to content

Commit

Permalink
test: create test_exists.py
Browse files Browse the repository at this point in the history
  • Loading branch information
ArVar authored Jul 1, 2024
1 parent e9fe88f commit 86086c6
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions tests/test_exists.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
import unittest

import numpy

from dedupe.variables.exists import ExistsType


class TestExists(unittest.TestCase):
def test_comparator(self):
var = ExistsType("foo")
assert numpy.array_equal(var.comparator(None, None), [0, 0])
assert numpy.array_equal(var.comparator(1, 1), [1, 0])
assert numpy.array_equal(var.comparator(1, 0), [0, 1])

0 comments on commit 86086c6

Please sign in to comment.