Skip to content

Commit

Permalink
Change class definitions from old style to new style
Browse files Browse the repository at this point in the history
  • Loading branch information
thombashi committed Jul 22, 2017
1 parent 226a33e commit d0b5377
Show file tree
Hide file tree
Showing 11 changed files with 17 additions and 17 deletions.
2 changes: 1 addition & 1 deletion test/checker/test_checker_datetime.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
inf = float("inf")


class Test_DateTime_is_type:
class Test_DateTime_is_type(object):

@pytest.mark.parametrize(
["value", "strict_level", "expected"],
Expand Down
2 changes: 1 addition & 1 deletion test/checker/test_checker_dictionary.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
inf = float("inf")


class Test_Dictionary_is_type:
class Test_Dictionary_is_type(object):

@pytest.mark.parametrize(
["value", "strict_level", "expected"],
Expand Down
2 changes: 1 addition & 1 deletion test/checker/test_checker_infinite.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
inf = float("inf")


class Test_Infinity_is_type:
class Test_Infinity_is_type(object):

@pytest.mark.parametrize(
["value", "strict_level", "expected"],
Expand Down
4 changes: 2 additions & 2 deletions test/checker/test_checker_integer.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,19 +11,19 @@
import itertools

import pytest
import six
from typepy import (
Typecode,
StrictLevel,
)
from typepy.type import Integer
import six


nan = float("nan")
inf = float("inf")


class Test_Integer_is_type:
class Test_Integer_is_type(object):

@pytest.mark.parametrize(["value", "strict_level", "expected"], [
[str(six.MAXSIZE), StrictLevel.MIN, True],
Expand Down
2 changes: 1 addition & 1 deletion test/checker/test_checker_list.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
inf = float("inf")


class Test_List_is_type:
class Test_List_is_type(object):

@pytest.mark.parametrize(
["value", "strict_level", "expected"],
Expand Down
2 changes: 1 addition & 1 deletion test/checker/test_checker_nan.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
inf = float("inf")


class Test_Nan_is_type:
class Test_Nan_is_type(object):

@pytest.mark.parametrize(
["value", "strict_level", "expected"],
Expand Down
2 changes: 1 addition & 1 deletion test/checker/test_checker_none.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
inf = float("inf")


class Test_NoneTypeChecker_is_type:
class Test_NoneTypeChecker_is_type(object):

@pytest.mark.parametrize(
["value", "strict_level", "expected"],
Expand Down
2 changes: 1 addition & 1 deletion test/checker/test_checker_realnumber.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
inf = float("inf")


class Test_RealNumber_is_type:
class Test_RealNumber_is_type(object):

@pytest.mark.parametrize(
["value", "strict_level", "expected"],
Expand Down
4 changes: 2 additions & 2 deletions test/checker/test_checker_string.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
inf = float("inf")


class Test_String_is_type:
class Test_String_is_type(object):

@pytest.mark.parametrize(
["value", "strict_level", "expected"],
Expand Down Expand Up @@ -53,7 +53,7 @@ def test_normal(self, value, strict_level, expected):
assert type_checker.typecode == Typecode.STRING


class Test_NullString_is_type:
class Test_NullString_is_type(object):

@pytest.mark.parametrize(["value", "strict_level", "expected"], [
[None, StrictLevel.MIN, True]
Expand Down
8 changes: 4 additions & 4 deletions test/test_function.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
inf = float("inf")


class Test_is_hex:
class Test_is_hex(object):

@pytest.mark.parametrize(["value"], [
["0x00"], ["0xffffffff"], ["a"], ["f"],
Expand All @@ -41,7 +41,7 @@ def test_abnormal(self, value):
assert not is_hex(value)


class Test_is_list_or_tuple:
class Test_is_list_or_tuple(object):

@pytest.mark.parametrize(["value", "expected"], [
[[], True],
Expand All @@ -61,7 +61,7 @@ def test_normal(self, value, expected):
assert is_list_or_tuple(value) == expected


class Test_is_empty_sequence:
class Test_is_empty_sequence(object):

@pytest.mark.parametrize(["value", "expected"], [
[(), True],
Expand All @@ -87,7 +87,7 @@ def test_normal(self, value, expected):
assert is_empty_sequence(value) == expected


class Test_is_not_empty_sequence:
class Test_is_not_empty_sequence(object):

@pytest.mark.parametrize(["value", "expected"], [
[[1], True],
Expand Down
4 changes: 2 additions & 2 deletions test/test_str_function.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
inf = float("inf")


class Test_is_not_empty_string:
class Test_is_not_empty_string(object):

@pytest.mark.parametrize(
["value", "expected"],
Expand All @@ -34,7 +34,7 @@ def test_normal(self, value, expected):
assert is_not_null_string(value) == expected


class Test_is_empty_string:
class Test_is_empty_string(object):

@pytest.mark.parametrize(
["value", "expected"],
Expand Down

0 comments on commit d0b5377

Please sign in to comment.