コード例 #1
0
        public void CreateUniqueId_FromIUniquelyIdentifiable() {
            // Arrange
            CustomUniquelyIdentifiable custom = new CustomUniquelyIdentifiable("hello-world");

            // Act
            string retVal = DescriptorUtil.CreateUniqueId(custom);

            // Assert
            Assert.AreEqual("[11]hello-world", retVal);
        }
コード例 #2
0
        public void CreateUniqueId_FromIUniquelyIdentifiable()
        {
            // Arrange
            CustomUniquelyIdentifiable custom = new CustomUniquelyIdentifiable("hello-world");

            // Act
            string retVal = DescriptorUtil.CreateUniqueId(custom);

            // Assert
            Assert.Equal("[11]hello-world", retVal);
        }
コード例 #3
0
        public void AppendUniqueId_FromIUniquelyIdentifiable()
        {
            // Arrange
            CustomUniquelyIdentifiable custom = new CustomUniquelyIdentifiable("hello-world");
            StringBuilder builder             = new StringBuilder();

            // Act
            DescriptorUtil.AppendUniqueId(builder, custom);

            // Assert
            Assert.Equal("[11]hello-world", builder.ToString());
        }
コード例 #4
0
        public void AppendUniqueId_FromIUniquelyIdentifiable()
        {
            // Arrange
            CustomUniquelyIdentifiable custom = new CustomUniquelyIdentifiable("hello-world");
            StringBuilder builder = new StringBuilder();

            // Act
            DescriptorUtil.AppendUniqueId(builder, custom);

            // Assert
            Assert.Equal("[11]hello-world", builder.ToString());
        }