我有一個jbehave的故事,我將一個字符串作爲數據傳遞給參數。 例子: |line|
|hi.how ade you|
它給誤差 expected hi.how are you But is :
hi
how are you
那麼,如何處理這個輸入的數據...因爲如果我給\n這是考慮它作爲數據的一部分
我在尋找可以構建更靈活場景的機制。 例如,對於在數據庫中記錄測試的存在,這兩個非常相似的場景: Scenario Outline: Testing query with 1 attribute with these 2 record in and another 2 out of result
Given I'm connected to <db> database
When
所以這裏是我的測試。 When(/^the admin user broadcasts "([^"]*)" to the notification feed$/) do |userBroadcast|
visit('/broadcasts/new.html')
fill_in('.nifty_form', with: userBroadcast)
click_butt
我開始用BDD方法編寫iOS單元測試。我有一個關於guard聲明並獲得100%代碼覆蓋率的問題。 我有以下代碼,該代碼處理將Data轉換爲Customer對象。 internal final class func customer(from data: Data) -> Customer? {
do {
guard let jsonDictionary = try JSONS