def test_center(self, size):
        SUBSTR = ' abc def ghi'
        s = SUBSTR.center(size)
        self.assertEquals(len(s), size)
        lpadsize = rpadsize = (len(s) - len(SUBSTR)) // 2
        if len(s) % 2:
            lpadsize += 1
        self.assertEquals(s[lpadsize:-rpadsize], SUBSTR)
        self.assertEquals(s.strip(), SUBSTR.strip())