def METHOD_NAME(self):
    self.assertEqual(basename("foo/bar/baz"), "baz")
    self.assertEqual(basename("foo/bar"), "bar")
    self.assertEqual(basename("foo"), "foo")
    self.assertEqual(basename("foo/bar/"), "")