public void Cross_ThreeTimesTwoOnItself_SixRowsFiveColumns() { var manager = new TestCaseCollectionManager(); var tc1 = manager.Item("alpha"); Load(tc1.Content, new string[] { "a11,a12", "a21,a22", "a31,a32" }, "alpha1,alpha2"); var tc2 = manager.Item("beta"); Load(tc2.Content, new string[] { "b11,b12,b13", "b21,b22,b23" }, "beta1,beta2,beta3"); manager.Cross("alpha", "beta"); //The focus hasn't moved ... so still on tc1 Assert.That(tc1.Content.Rows, Has.Count.EqualTo(6)); Assert.That(tc1.Content.Columns, Has.Count.EqualTo(5)); }
public void Cross_ThreeTimesTwoOnMatchingColumnWithoutPrimaryKey_FiveRowsFourColumns() { var manager = new TestCaseCollectionManager(); var tc1 = manager.Item("alpha"); Load(tc1.Content, new string[] { "a11,a12", "a11,a22", "a21,a32" }, "alpha1,alpha2"); var tc2 = manager.Item("beta"); Load(tc2.Content, new string[] { "a11,b12,b13", "a21,b22,b23", "a21,b32,b33", "a21,b42,b43", "a41,b52,b53" }, "alpha1,beta2,beta3"); manager.SetFocus("gamma"); manager.Cross("alpha", "beta", "alpha1"); var focus = manager.Scope; Assert.That(focus.Content.Rows, Has.Count.EqualTo(5)); Assert.That(focus.Content.Columns, Has.Count.EqualTo(4)); }
public void Cross_ThreeTimesTwoWithOneCommonColumnName_SixRowsFourColumns() { var manager = new TestCaseCollectionManager(); var tc1 = manager.Item("alpha"); Load(tc1.Content, new string[] { "a11,a12", "a21,a22", "a31,a32" }, "alpha1,alpha2"); var tc2 = manager.Item("beta"); Load(tc2.Content, new string[] { "b11,b12,b13", "b21,b22,b23" }, "alpha1,beta2,beta3"); manager.SetFocus("gamma"); manager.Cross("alpha", "beta"); var focus = manager.Scope; Assert.That(focus.Content.Rows, Has.Count.EqualTo(6)); Assert.That(focus.Content.Columns, Has.Count.EqualTo(4)); }