Interface AssertOnColumnContent<T extends AssertOnColumnContent<T>>

Type Parameters:
T - The "self" type of this assertion class. Please read "Emulating 'self types' using Java Generics to simplify fluent API implementation" for more details.
All Known Implementing Classes:
AbstractColumnAssert, RequestColumnAssert, TableColumnAssert

public interface AssertOnColumnContent<T extends AssertOnColumnContent<T>>
Defines the assertion methods on the content of a column.
Since:
1.1.0
Author:
Régis Pouiller
  • Method Details

    • containsValues

      T containsValues(Object... expected)
      Verifies that the values of a column contains objects.

      Example where the assertion verifies that the values in the first Column of the Table are containing the objects in parameter :

      
       assertThat(table).column().containsValues(Locale.FRENCH, Locale.ENGLISH, Locale.FRENCH);
       
      Parameters:
      expected - The expected object values.
      Returns:
      this assertion object.
      Throws:
      AssertionError - If the column are not containing the objects in parameter.
      See Also:
    • containsValues

      T containsValues(Boolean... expected)
      Verifies that the values of a column contains booleans.

      Example where the assertion verifies that the values in the first Column of the Table are containing the booleans in parameter :

      
       assertThat(table).column().containsValues(true, false, true);
       
      Parameters:
      expected - The expected boolean values.
      Returns:
      this assertion object.
      Throws:
      AssertionError - If the column are not containing the booleans in parameter.
      See Also:
    • containsValues

      T containsValues(Number... expected)
      Verifies that the values of a column contains numbers.

      Example where the assertion verifies that the values in the first Column of the Table are containing the numbers in parameter :

      
       assertThat(table).column().containsValues(5, 10.5, 6);
       
      Parameters:
      expected - The expected numbers values.
      Returns:
      this assertion object.
      Throws:
      AssertionError - If the column are not containing the numbers in parameter.
      See Also:
    • containsValues

      T containsValues(byte[]... expected)
      Verifies that the values of a column contains bytes.

      Example where the assertion verifies that the values in the first Column of the Table are containing arrays of bytes loaded from files in the classpath :

      
       byte[] bytes1 = bytesContentFromClassPathOf("file1.png");
       byte[] bytes2 = bytesContentFromClassPathOf("file2.png");
       assertThat(table).column().containsValues(bytes1, bytes2);
       
      Parameters:
      expected - The expected bytes values.
      Returns:
      this assertion object.
      Throws:
      AssertionError - If the column are not containing the bytes in parameter.
      See Also:
    • containsValues

      T containsValues(String... expected)
      Verifies that the values of a column contains texts.

      Example where the assertion verifies that the values in the first Column of the Table are containing the texts in parameter :

      
       assertThat(table).column().containsValues("text", "text2", "text3");
       
      Parameters:
      expected - The expected text values.
      Returns:
      this assertion object.
      Throws:
      AssertionError - If the column are not containing the texts in parameter.
      See Also:
    • containsValues

      T containsValues(Character... expected)
      Verifies that the values of a column contains characters.

      Example where the assertion verifies that the values in the first Column of the Table are containing the characters in parameter :

      
       assertThat(table).column().containsValues('t', 'e', 'x', 't');
       
      Parameters:
      expected - The expected character values.
      Returns:
      this assertion object.
      Throws:
      AssertionError - If the column are not containing the characters in parameter.
      Since:
      1.2.0
      See Also:
    • containsValues

      T containsValues(UUID... expected)
      Verifies that the values of a column containsUUIDs.

      Example where the assertion verifies that the values in the first Column of the Table are containing the UUIDs in parameter :

      
       assertThat(table).column().containsValues(UUID.fromString("30B443AE-C0C9-4790-9BEC-CE1380808435"),
       UUID.fromString("16319617-AE95-4087-9264-D3D21BF611B6"), UUID.fromString("D735221B-5DE5-4112-AA1E-49090CB75ADA"));
       
      Parameters:
      expected - The expected UUID values.
      Returns:
      this assertion object.
      Throws:
      AssertionError - If the column are not containing the UUIDs in parameter.
      See Also:
    • containsValues

      T containsValues(DateValue... expected)
      Verifies that the values of a column contains date values.

      Example where the assertion verifies that the values in the first Column of the Table are containing the date values in parameter :

      
       assertThat(table).column().containsValues(DateValue.of(2014, 7, 7), DateValue.of(2014, 10, 3),
           DateValue.of(2014, 12, 23));
       
      Parameters:
      expected - The expected date values.
      Returns:
      this assertion object.
      Throws:
      AssertionError - If the column are not containing the date values in parameter.
      See Also:
    • containsValues

      T containsValues(TimeValue... expected)
      Verifies that the values of a column contains time values.

      Example where the assertion verifies that the values in the first Column of the Table are containing the time values in parameter :

      
       assertThat(table).column().containsValues(TimeValue.of(21, 29, 30), TimeValue.of(10, 1, 25), TimeValue.of(9, 1));
       
      Parameters:
      expected - The expected time values.
      Returns:
      this assertion object.
      Throws:
      AssertionError - If the column are not containing the time values in parameter.
      See Also:
    • containsValues

      T containsValues(DateTimeValue... expected)
      Verifies that the values of a column contains date/time values.

      Example where the assertion verifies that the values in the first Column of the Table are containing the date/time values in parameter :

      
       assertThat(table).column().containsValues(DateTimeValue.of(DateValue.of(2014, 7, 7), TimeValue.of(21, 29)),
           DateTimeValue.of(DateValue.of(2014, 7, 7), TimeValue.of(10, 1, 25)),
           DateTimeValue.of(DateValue.of(2014, 7, 7), TimeValue.of(9, 1)));
       
      Parameters:
      expected - The expected date/time values.
      Returns:
      this assertion object.
      Throws:
      AssertionError - If the column are not containing the date/time values in parameter.
      See Also: