def test_french_republican_schematic_romme(self):
        self.assertEqual(self.gregoriandate, fr.to_gregorian(
            *fr.from_gregorian(*self.gregoriandate, method=100), method=100))

        self.assertEqual(self.jd, fr.to_jd(*fr.from_jd(self.jd, method='romme'), method=100))
        self.assertEqual(self.x, fr.to_jd(*fr.from_jd(self.x, method=100), method=100))
        assert self.j == fr.to_jd(*fr.from_jd(self.j, method=100), method=100)
 def test_french_republican_schematic_madler(self):
     self.assertEqual(self.j,
                      fr.to_jd(*fr.from_jd(self.j, method=128), method=128))
     self.assertEqual(self.x,
                      fr.to_jd(*fr.from_jd(self.x, method=128), method=128))
     self.assertEqual(
         self.jd, fr.to_jd(*fr.from_jd(self.jd, method=128), method=128))
    def test_french_republican_schematic_continuous(self):
        self.assertEqual(
            gregorian.from_jd(self.jd),
            fr.to_gregorian(*fr.from_jd(self.jd, method=4), method=4))
        self.assertEqual(self.x,
                         fr.to_jd(*fr.from_jd(self.x, method=4), method=4))

        assert self.j == fr.to_jd(*fr.from_jd(self.j, method='continuous'),
                                  method=4)
Esempio n. 4
0
    def test_french_republican_schematic_romme(self):
        self.assertEqual(
            self.gregoriandate,
            fr.to_gregorian(*fr.from_gregorian(*self.gregoriandate, method=100), method=100),
        )

        self.assertEqual(self.jd, fr.to_jd(*fr.from_jd(self.jd, method='romme'), method=100))
        self.assertEqual(self.x, fr.to_jd(*fr.from_jd(self.x, method=100), method=100))
        assert self.j == fr.to_jd(*fr.from_jd(self.j, method=100), method=100)
    def test_french_republican(self):
        assert self.jd == fr.to_jd(*fr.from_jd(self.jd))
        assert fr.from_gregorian(2014, 6, 14) == (222, 9, 26)
        assert (2014, 6, 14) == fr.to_gregorian(222, 9, 26)

        assert (3, 13, 6) == fr.from_gregorian(1795, 9, 22)

        for jd in range(2378822, 2488395, 2000):
            self.assertEqual(jd + 0.5, gregorian.to_jd(*gregorian.from_jd(jd + 0.5)))
Esempio n. 6
0
    def test_french_republican(self):
        assert self.jd == fr.to_jd(*fr.from_jd(self.jd))
        assert fr.from_gregorian(2014, 6, 14) == (222, 9, 26)
        assert (2014, 6, 14) == fr.to_gregorian(222, 9, 26)

        assert (3, 13, 6) == fr.from_gregorian(1795, 9, 22)

        for jd in range(2378822, 2488395, 2000):
            self.assertEqual(jd + 0.5, gregorian.to_jd(*gregorian.from_jd(jd + 0.5)))
    def test_french_republican_schematic_continuous(self):
        self.assertEqual(gregorian.from_jd(self.jd), fr.to_gregorian(*fr.from_jd(self.jd, method=4), method=4))
        self.assertEqual(self.x, fr.to_jd(*fr.from_jd(self.x, method=4), method=4))

        assert self.j == fr.to_jd(*fr.from_jd(self.j, method='continuous'), method=4)
 def test_french_republican_schematic_madler(self):
     self.assertEqual(self.j, fr.to_jd(*fr.from_jd(self.j, method=128), method=128))
     self.assertEqual(self.x, fr.to_jd(*fr.from_jd(self.x, method=128), method=128))
     self.assertEqual(self.jd, fr.to_jd(*fr.from_jd(self.jd, method=128), method=128))