예제 #1
0
        public void TestAuthor()
        {
            var post = new BlogDB.Core.Post("", new Author("author", 0), "");

            Assert.Equal("author", post.Author.Name);
            Assert.Equal(0, post.Author.ID);
        }
예제 #2
0
        public void TestPostID()
        {
            var guid = Guid.NewGuid();
            var post = new BlogDB.Core.Post("", new Author("", 0), "", DateTime.UtcNow, guid);

            Assert.Equal(guid, post.PostID);
        }
예제 #3
0
        public void TestDateTime()
        {
            var date = DateTime.UtcNow;
            var post = new BlogDB.Core.Post("", new Author("", 0), "", date, Guid.NewGuid());

            Assert.Equal(date, post.Timestamp);
        }
예제 #4
0
        public void TestBody()
        {
            var post = new BlogDB.Core.Post("", new Author("", 0), "body");

            Assert.Equal("body", post.Body);
        }
예제 #5
0
        public void TestTitle()
        {
            var post = new BlogDB.Core.Post("title", new Author("", 0), "");

            Assert.Equal("title", post.Title);
        }