Example #1
0
    def test_endsInNewline(self):
        """
        L{text.endsInNewline} returns C{True} if the string ends in a newline.
        """
        s = "newline\n"
        m = text.endsInNewline(s)
        self.assertTrue(m)

        s = "oldline"
        m = text.endsInNewline(s)
        self.assertFalse(m)
Example #2
0
    def test_endsInNewline(self):
        """
        L{text.endsInNewline} returns C{True} if the string ends in a newline.
        """
        s = 'newline\n'
        m = text.endsInNewline(s)
        self.assertTrue(m)

        s = 'oldline'
        m = text.endsInNewline(s)
        self.assertFalse(m)