Code Duplication    Length = 12-12 lines in 3 locations

tests/protocols/gmpv208/entities/schedules/test_create_schedule.py 3 locations

@@ 62-73 (lines=12) @@
59
        ex = cm.exception
60
        self.assertEqual(ex.argument, "icalendar")
61
62
    def test_missing_timezone(self):
63
        with self.assertRaises(RequiredArgument) as cm:
64
            self.gmp.create_schedule(name='foo', icalendar=ICAL, timezone=None)
65
66
        ex = cm.exception
67
        self.assertEqual(ex.argument, "timezone")
68
69
        with self.assertRaises(RequiredArgument) as cm:
70
            self.gmp.create_schedule(name='foo', icalendar=ICAL, timezone='')
71
72
        ex = cm.exception
73
        self.assertEqual(ex.argument, "timezone")
74
75
    def test_create_schedule(self):
76
        self.gmp.create_schedule(
@@ 49-60 (lines=12) @@
46
        ex = cm.exception
47
        self.assertEqual(ex.argument, "name")
48
49
    def test_missing_icalendar(self):
50
        with self.assertRaises(RequiredArgument) as cm:
51
            self.gmp.create_schedule(name='foo', icalendar=None, timezone='UTC')
52
53
        ex = cm.exception
54
        self.assertEqual(ex.argument, "icalendar")
55
56
        with self.assertRaises(RequiredArgument) as cm:
57
            self.gmp.create_schedule(name='foo', icalendar='', timezone='UTC')
58
59
        ex = cm.exception
60
        self.assertEqual(ex.argument, "icalendar")
61
62
    def test_missing_timezone(self):
63
        with self.assertRaises(RequiredArgument) as cm:
@@ 36-47 (lines=12) @@
33
34
35
class GmpCreateScheduleTestMixin:
36
    def test_missing_name(self):
37
        with self.assertRaises(RequiredArgument) as cm:
38
            self.gmp.create_schedule(name=None, icalendar=ICAL, timezone='UTC')
39
40
        ex = cm.exception
41
        self.assertEqual(ex.argument, "name")
42
43
        with self.assertRaises(RequiredArgument) as cm:
44
            self.gmp.create_schedule(name='', icalendar=ICAL, timezone='UTC')
45
46
        ex = cm.exception
47
        self.assertEqual(ex.argument, "name")
48
49
    def test_missing_icalendar(self):
50
        with self.assertRaises(RequiredArgument) as cm: