viff

changeset 760:591ab6199980

Test new actively secure comparison protocols.
author Martin Geisler <mg@daimi.au.dk>
date Thu, 15 May 2008 09:41:57 +0200
parents 16fe2bd2edec
children c947486e9535
files viff/test/test_runtime_comp.py
diffstat 1 files changed, 44 insertions(+), 0 deletions(-) [+]
line diff
     1.1 --- a/viff/test/test_runtime_comp.py	Thu May 15 09:41:27 2008 +0200
     1.2 +++ b/viff/test/test_runtime_comp.py	Thu May 15 09:41:57 2008 +0200
     1.3 @@ -20,6 +20,7 @@
     1.4  import operator
     1.5  
     1.6  from viff.comparison import Toft05Runtime, Toft07Runtime
     1.7 +from viff.comparison import ActiveToft05Runtime, ActiveToft07Runtime
     1.8  from viff.test.util import RuntimeTestCase, BinaryOperatorTestCase
     1.9  
    1.10  
    1.11 @@ -43,6 +44,28 @@
    1.12      operator = operator.le
    1.13  
    1.14  
    1.15 +
    1.16 +class ActiveToft05GreaterThanTest(BinaryOperatorTestCase, RuntimeTestCase):
    1.17 +    runtime_class = ActiveToft05Runtime
    1.18 +    operator = operator.gt
    1.19 +
    1.20 +
    1.21 +class ActiveToft05GreaterThanEqualTest(BinaryOperatorTestCase, RuntimeTestCase):
    1.22 +    runtime_class = ActiveToft05Runtime
    1.23 +    operator = operator.ge
    1.24 +
    1.25 +
    1.26 +class ActiveToft05LessThanTest(BinaryOperatorTestCase, RuntimeTestCase):
    1.27 +    runtime_class = ActiveToft05Runtime
    1.28 +    operator = operator.lt
    1.29 +
    1.30 +
    1.31 +class ActiveToft05LessThanEqualTest(BinaryOperatorTestCase, RuntimeTestCase):
    1.32 +    runtime_class = ActiveToft05Runtime
    1.33 +    operator = operator.le
    1.34 +
    1.35 +
    1.36 +
    1.37  class Toft07GreaterThanTest(BinaryOperatorTestCase, RuntimeTestCase):
    1.38      runtime_class = Toft07Runtime
    1.39      operator = operator.gt
    1.40 @@ -61,3 +84,24 @@
    1.41  class Toft07LessThanEqualTest(BinaryOperatorTestCase, RuntimeTestCase):
    1.42      runtime_class = Toft07Runtime
    1.43      operator = operator.le
    1.44 +
    1.45 +
    1.46 +
    1.47 +class ActiveToft07GreaterThanTest(BinaryOperatorTestCase, RuntimeTestCase):
    1.48 +    runtime_class = ActiveToft07Runtime
    1.49 +    operator = operator.gt
    1.50 +
    1.51 +
    1.52 +class ActiveToft07GreaterThanEqualTest(BinaryOperatorTestCase, RuntimeTestCase):
    1.53 +    runtime_class = ActiveToft07Runtime
    1.54 +    operator = operator.ge
    1.55 +
    1.56 +
    1.57 +class ActiveToft07LessThanTest(BinaryOperatorTestCase, RuntimeTestCase):
    1.58 +    runtime_class = ActiveToft07Runtime
    1.59 +    operator = operator.lt
    1.60 +
    1.61 +
    1.62 +class ActiveToft07LessThanEqualTest(BinaryOperatorTestCase, RuntimeTestCase):
    1.63 +    runtime_class = ActiveToft07Runtime
    1.64 +    operator = operator.le