예제 #1
0
        public void DataGridViewExtensionsClass_AddStartingRowsMethod_ThrowsArgumentNullException_IfFirstParameterIsNull()
        {
            DataGridView testObject = null;
            int          testParam1 = _rnd.Next();

            testObject.AddStartingRows(testParam1);

            Assert.Fail();
        }
예제 #2
0
        public void DataGridViewExtensionsClass_AddStartingRowsMethod_ThrowsArgumentNullExceptionWithCorrectParamNameProperty_IfFirstParameterIsNull()
        {
            DataGridView testObject = null;
            int          testParam1 = _rnd.Next();

            try
            {
                testObject.AddStartingRows(testParam1);
                Assert.Fail();
            }
            catch (ArgumentNullException ex)
            {
                Assert.AreEqual("grid", ex.ParamName);
            }
        }