add test case for setEditor method