コード例 #1
0
        public void should_open_a_connection_per_request()
        {
            strategy.Execute(c => { });
            strategy.Execute(c => true);
            connection.Received(2).Open();

            strategy.Execute(c => { });
            strategy.Execute(c => true);
            connection.Received(4).Open();
        }
コード例 #2
0
 public void should_not_open_a_connection_per_request()
 {
     strategy.Execute(c => { });
     strategy.Execute(c => true);
     connection.DidNotReceive().Open();
 }