7 writes to Blend
System.Drawing.Common.Tests (7)
System\Drawing\Drawing2D\PathGradientBrushTests.cs (7)
257brush.Blend = new Blend { Factors = factors, Positions = positions }; 309AssertExtensions.Throws<ArgumentException>(null, () => brush.Blend = blend); 318AssertExtensions.Throws<ArgumentException>("value", null, () => brush.Blend = invalidBlend); 325Assert.Throws<ArgumentNullException>(() => brush.Blend = null); 326Assert.Throws<ArgumentNullException>(() => brush.Blend = new Blend() { Factors = null, Positions = null }); 327Assert.Throws<ArgumentNullException>(() => brush.Blend = new Blend() { Factors = null, Positions = [] }); 335brush.Blend = new Blend() { Factors = [], Positions = null });
61 references to Blend
System.Drawing.Common.Tests (61)
System\Drawing\Drawing2D\PathGradientBrushTests.cs (61)
258Assert.Equal(factors, brush.Blend.Factors); 259Assert.Equal(expectedSize, brush.Blend.Positions.Length); 262Assert.Equal(factors, brush.Blend.Factors); 263Assert.Equal(positions, brush.Blend.Positions); 267Assert.Equal(factors, brush.Blend.Factors); 268Assert.Single(brush.Blend.Positions); 276brush.Blend.Factors = []; 277Assert.Single(brush.Blend.Factors); 278brush.Blend.Factors = new float[2]; 279Assert.Single(brush.Blend.Factors); 280brush.Blend.Positions = []; 281Assert.Single(brush.Blend.Positions); 282brush.Blend.Positions = new float[2]; 283Assert.Single(brush.Blend.Positions); 292AssertExtensions.Throws<ArgumentException>(null, () => brush.Blend); 351Assert.Equal(focus, brush.Blend.Positions[0]); 352Assert.Equal(defaultScale, brush.Blend.Factors[0]); 353Assert.Equal(1f, brush.Blend.Positions[^1]); 354Assert.Equal(0f, brush.Blend.Factors[^1]); 358Assert.Equal(0f, brush.Blend.Positions[0]); 359Assert.Equal(0f, brush.Blend.Factors[0]); 360Assert.Equal(focus, brush.Blend.Positions[^1]); 361Assert.Equal(defaultScale, brush.Blend.Factors[^1]); 365Assert.Equal(0f, brush.Blend.Positions[0]); 366Assert.Equal(0f, brush.Blend.Factors[0]); 367Assert.Equal(1f, brush.Blend.Positions[^1]); 368Assert.Equal(0f, brush.Blend.Factors[^1]); 383Assert.Equal(256, brush.Blend.Positions.Length); 384Assert.Equal(256, brush.Blend.Factors.Length); 385Assert.Equal(focus, brush.Blend.Positions[0]); 386Assert.Equal(1f, brush.Blend.Factors[0]); 387Assert.Equal(1f, brush.Blend.Positions[^1]); 388Assert.Equal(0f, brush.Blend.Factors[^1]); 392Assert.Equal(256, brush.Blend.Positions.Length); 393Assert.Equal(256, brush.Blend.Factors.Length); 394Assert.Equal(0f, brush.Blend.Positions[0]); 395Assert.Equal(0f, brush.Blend.Factors[0]); 396Assert.Equal(focus, brush.Blend.Positions[^1]); 397Assert.Equal(1f, brush.Blend.Factors[^1]); 401Assert.Equal(511, brush.Blend.Positions.Length); 402Assert.Equal(511, brush.Blend.Factors.Length); 403Assert.Equal(0f, brush.Blend.Positions[0]); 404Assert.Equal(0f, brush.Blend.Factors[0]); 405Assert.Equal(focus, brush.Blend.Positions[255]); 406Assert.Equal(1f, brush.Blend.Factors[255]); 407Assert.Equal(1f, brush.Blend.Positions[^1]); 408Assert.Equal(0f, brush.Blend.Factors[^1]); 454Assert.Equal([defaultScale, 0f], brush.Blend.Factors); 455Assert.Equal([focus, 1f], brush.Blend.Positions); 459Assert.Equal([0f, defaultScale], brush.Blend.Factors); 460Assert.Equal([0f, focus], brush.Blend.Positions); 464Assert.Equal([0f, defaultScale, 0f], brush.Blend.Factors); 465Assert.Equal([0f, focus, 1f], brush.Blend.Positions); 481Assert.Equal([1f, 0f], brush.Blend.Factors); 482Assert.Equal([focus, 1f], brush.Blend.Positions); 486Assert.Equal([0f, 1f], brush.Blend.Factors); 487Assert.Equal([0f, focus], brush.Blend.Positions); 491Assert.Equal([0f, 1f, 0f], brush.Blend.Factors); 492Assert.Equal([0f, focus, 1f], brush.Blend.Positions); 943Assert.Equal([1], brush.Blend.Factors); 944Assert.Single(brush.Blend.Positions);