????д??UI????????????????????????????????糿??????????????????????failed????????“?????????????”???????log???????????????????????????????????????????????????xpath??λ?????????λ???????????????????????????仯???????????????????????Щ ????????????????ok???????????????????????????????????????????????????????????Щ?????????С?????????????????????? ???о?????????????????????????????дUI??????????а?????????????????????????Selenium?????

????1??text?????????????????????????text??

??????1????????????????

?????????????????漲???????????С??5???????????????????У?????????4?????????????????????????????????????????10%??

??????2????????

??????δ?????????????£????????????name.lofter.com??????focus???????????е????name???????????????????????????????????focus?????????????????????????????????????2?????????????????

??????3?????????????????????????????????????ù??λ??????????

public static void createSubBlog(BrowserEmulator be?? String blogname??
            String blogadr?? String vercode?? int result)
            throws InterruptedException {
        be.open(http://www.lofter.com/newblog);
        be.type(???_???_????????????? blogname);
        be.getBrowser().focus(???_???_???????????);
        be.type(???_???_??????????? blogadr);
        be.type(???_???_?????????? vercode);
        be.click(???_???_???????);

        // ???
        if (result == 1) {
            be.expectElementExistOrNot(true?? String.format(????_??????????? blogname)??
                    10000);
        }
        if (result == 0) {
            be.click(????_????);
            be.expectElementExistOrNot(false??
                    String.format(????_??????????? blogname)?? 5000);
        }
    }