public void TableLayoutColumnStyleCollection_IndexOf_Invoke_ReturnsExpected() { using var toolStrip = new ToolStrip { LayoutStyle = ToolStripLayoutStyle.Table }; TableLayoutSettings settings = Assert.IsType <TableLayoutSettings>(toolStrip.LayoutSettings); TableLayoutColumnStyleCollection collection = settings.ColumnStyles; var style = new ColumnStyle(); collection.Add(style); Assert.Equal(0, collection.IndexOf(style)); Assert.Equal(-1, collection.IndexOf(new ColumnStyle())); Assert.Equal(-1, collection.IndexOf(null)); }