public void ToString_MultipleVariablesInTruthTable_NumberOfPiecesShouldBeEquivalentToNumberOfVariablesPlusOneForResultColumn(string toParseExpression) { // Arrange parser = new Parser(toParseExpression); Proposition root = parser.Parse(); TruthTable tt = new TruthTable(root); int numberOfVariables = root.GetVariables().Count; int numberOfExpectedParts = numberOfVariables + 1; // Act String result = tt.TableHeader(); String[] parts = result.Split(TruthTableRow.GetPadding()); // Assert parts.Length.Should().Be(numberOfExpectedParts, "Because the string should display a value for each variable and a result"); }