コード例 #1
0
        public void CreateRandomQuote_creates_quote()
        {
            // arrange
            var factory = new QuoteFactory();

            // act
            var quote = factory.CreateRandomQuote();

            // assert
            Assert.IsNotNull(quote);
        }
コード例 #2
0
        public void CreateRandomQuote_respects_my_authority()
        {
            // arrange
            var factory            = new QuoteFactory();
            var allowedIdentifiers = new Identifiers(new List <string> {
                "SBUX"
            });
            // act
            var quote = factory.CreateRandomQuote(allowedIdentifiers);

            // assert
            Assert.That(quote.Identifier, Is.EqualTo("SBUX"));
        }