こんにちは、特定の方法でパスしようとしているこの rspec テストについて助けが必要です。問題は、それが何を求めているのかわからないことです。これが私が合格しようとしているテストです。
describe "repeater" do
it "executes the default block" do
block_was_executed = false
repeater do
block_was_executed = true
end
block_was_executed.should == true
end
it "executes the default block 3 times" do
n = 0
repeater(3) do
n += 1
end
n.should == 3
end
it "executes the default block 10 times" do
n = 0
repeater(10) do
n += 1
end
n.should == 10
end
end
このテストに合格するために何をする必要があるのか よくわかりません。なぜなら、それが何を求めているのかわからないからです。実際にコードを渡さずに言葉で説明できれば、それは素晴らしいことです!