は、私は私のサイト(マイプロファイル)に要素のテキストが必要ですが、作業やジャスミン上のコードを実行されるコードイマイチは私にここにのgetText()
は次のエラーを与える作業ありえない私コード
describe("login to CA", function() {
it("returns successful", function() {
driver.get(url);
driver.findElement(By.xpath('//*[@id="input-username"]')).sendKeys(username);
driver.findElement(By.xpath('//*[@id="input-password"]')).sendKeys(pw);
driver.findElement(By.xpath('//*[@id="submit"]')).click();
myProfile = driver.findElement(By.css('#bs-example-navbar-collapse-1 > ul > li:nth-child(5) > a'));
expect(myProfile.getText()).toEqual('My profile');
});
});
どうすればよいですか?