本文整理匯總了Golang中github.com/sclevine/agouti.Page.Title方法的典型用法代碼示例。如果您正苦於以下問題:Golang Page.Title方法的具體用法?Golang Page.Title怎麽用?Golang Page.Title使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類github.com/sclevine/agouti.Page
的用法示例。
在下文中一共展示了Page.Title方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Golang代碼示例。
示例1:
Origin: event.Origin{
Name: "origin-name",
Type: event.OriginTypeTask,
Source: event.OriginSourceStdout,
Location: location,
},
Payload: "hello this is a payload",
})
})
It("can abort the build", func() {
// homepage -> job detail w/build info
Expect(page.Navigate(homepage())).To(Succeed())
Authenticate(page, "admin", "password")
title, err := page.Title()
Ω(err).ShouldNot(HaveOccurred())
Ω(title).Should(Equal(fmt.Sprintf("%s - Concourse", atc.DefaultPipelineName)))
Eventually(page.FindByLink("job-name")).Should(BeFound())
Expect(page.FindByLink("job-name").Click()).To(Succeed())
// job detail w/build info -> abort build
Expect(page).Should(HaveURL(withPath(fmt.Sprintf("jobs/job-name/builds/%d", build.ID))))
Expect(page.Find("h1")).To(HaveText(fmt.Sprintf("job-name #%d", build.ID)))
Expect(page.Find(".js-abortBuild").Click()).To(Succeed())
Expect(page).Should(HaveURL(withPath(fmt.Sprintf("jobs/job-name/builds/%d", build.ID))))
Eventually(page.Find("#page-header.aborted")).Should(BeFound())
Eventually(page.Find(".js-abortBuild")).ShouldNot(BeFound())