from test_calendar import CalendarTest

from qual.calendars import EnglishHistoricalCalendar

class TestHistoricalCalendar(object):
    def setUp(self):
        self.calendar = self.calendar_type()

    def test_before_switch(self):
        for triplet in self.julian_triplets:
            self.check_valid_date(*triplet)

    def test_after_switch(self):
        for triplet in self.gregorian_triplets:
            self.check_valid_date(*triplet)

    def test_during_switch(self):
        for triplet in self.transition_triplets:
            self.check_invalid_date(*triplet)

class TestEnglishHistoricalCalendar(TestHistoricalCalendar, CalendarTest):
    calendar_type = EnglishHistoricalCalendar
    gregorian_triplets = [(1752, 9, 13)]
    julian_triplets = [(1752, 9, 1)]
    transition_triplets = [(1752, 9, 6)]

from test_calendar import CalendarTest

from qual.calendars import EnglishHistoricalCalendar

class TestHistoricalCalendar(object):
    def setUp(self):
        self.calendar = self.calendar_type()

    def test_before_switch(self):
        for triplet in self.julian_triplets:
            self.check_valid_date(*triplet)

    def test_after_switch(self):
        for triplet in self.gregorian_triplets:
            self.check_valid_date(*triplet)

    def test_during_switch(self):
        for triplet in self.transition_triplets:
            self.check_invalid_date(*triplet)

class TestEnglishHistoricalCalendar(TestHistoricalCalendar, CalendarTest):
    calendar_type = EnglishHistoricalCalendar
    gregorian_triplets = [(1752, 9, 14)]
    julian_triplets = [(1752, 9, 1), (1752, 9, 2)]
    transition_triplets = [(1752, 9, 3), (1752, 9, 6), (1752, 9, 13)]

Correct test for the right missing days and present days.
Correct test for the right missing days and present days.

1st and 2nd of September 1752 happened, so did 14th. 3rd to 13th did not.

  from test_calendar import CalendarTest
  
  from qual.calendars import EnglishHistoricalCalendar
  
  class TestHistoricalCalendar(object):
      def setUp(self):
          self.calendar = self.calendar_type()
  
      def test_before_switch(self):
          for triplet in self.julian_triplets:
              self.check_valid_date(*triplet)
  
      def test_after_switch(self):
          for triplet in self.gregorian_triplets:
              self.check_valid_date(*triplet)
  
      def test_during_switch(self):
          for triplet in self.transition_triplets:
              self.check_invalid_date(*triplet)
  
  class TestEnglishHistoricalCalendar(TestHistoricalCalendar, CalendarTest):
      calendar_type = EnglishHistoricalCalendar
-     gregorian_triplets = [(1752, 9, 13)]
+     gregorian_triplets = [(1752, 9, 14)]
-     julian_triplets = [(1752, 9, 1)]
+     julian_triplets = [(1752, 9, 1), (1752, 9, 2)]
-     transition_triplets = [(1752, 9, 6)]
+     transition_triplets = [(1752, 9, 3), (1752, 9, 6), (1752, 9, 13)]
  
Correct test for the right missing days and present days.
## Code Before:
from test_calendar import CalendarTest

from qual.calendars import EnglishHistoricalCalendar

class TestHistoricalCalendar(object):
    def setUp(self):
        self.calendar = self.calendar_type()

    def test_before_switch(self):
        for triplet in self.julian_triplets:
            self.check_valid_date(*triplet)

    def test_after_switch(self):
        for triplet in self.gregorian_triplets:
            self.check_valid_date(*triplet)

    def test_during_switch(self):
        for triplet in self.transition_triplets:
            self.check_invalid_date(*triplet)

class TestEnglishHistoricalCalendar(TestHistoricalCalendar, CalendarTest):
    calendar_type = EnglishHistoricalCalendar
    gregorian_triplets = [(1752, 9, 13)]
    julian_triplets = [(1752, 9, 1)]
    transition_triplets = [(1752, 9, 6)]

## Instruction:
Correct test for the right missing days and present days.
## Code After:
from test_calendar import CalendarTest

from qual.calendars import EnglishHistoricalCalendar

class TestHistoricalCalendar(object):
    def setUp(self):
        self.calendar = self.calendar_type()

    def test_before_switch(self):
        for triplet in self.julian_triplets:
            self.check_valid_date(*triplet)

    def test_after_switch(self):
        for triplet in self.gregorian_triplets:
            self.check_valid_date(*triplet)

    def test_during_switch(self):
        for triplet in self.transition_triplets:
            self.check_invalid_date(*triplet)

class TestEnglishHistoricalCalendar(TestHistoricalCalendar, CalendarTest):
    calendar_type = EnglishHistoricalCalendar
    gregorian_triplets = [(1752, 9, 14)]
    julian_triplets = [(1752, 9, 1), (1752, 9, 2)]
    transition_triplets = [(1752, 9, 3), (1752, 9, 6), (1752, 9, 13)]
