Beispiel #1
0
        public void DocumentOptionsExtensionsClass_ToDocumentOptionsModelMethod_ThrowsArgumentNullException_IfParameterIsNull()
        {
            DocumentOptions testObject = null;

            _ = testObject.ToDocumentOptionsModel();

            Assert.Fail();
        }
Beispiel #2
0
        public void DocumentOptionsExtensionsClass_ToDocumentOptionsModelMethod_SetsGraphEditStylePropertyToCorrectValue_IfArgumentGraphEditStylePropertyEqualsPreserveSectionTimes()
        {
            DocumentOptions testObject = new DocumentOptions {
                GraphEditStyle = GraphEditStyle.PreserveSectionTimes
            };

            DocumentOptionsModel testOutput = testObject.ToDocumentOptionsModel();

            Assert.AreEqual("PreserveSectionTimes", testOutput.GraphEditStyle);
        }
Beispiel #3
0
        public void DocumentOptionsExtensionsClass_ToDocumentOptionsModelMethod_ThrowsArgumentNullExceptionWithCorrectParamNameProperty_IfParameterIsNull()
        {
            DocumentOptions testObject = null;

            try
            {
                _ = testObject.ToDocumentOptionsModel();
                Assert.Fail();
            }
            catch (ArgumentNullException ex)
            {
                Assert.AreEqual("options", ex.ParamName);
            }
        }