Class ShouldHaveContent

    • Constructor Detail

      • ShouldHaveContent

        private ShouldHaveContent​(java.io.File actual,
                                  java.nio.charset.Charset charset,
                                  java.lang.String diffs)
      • ShouldHaveContent

        private ShouldHaveContent​(java.nio.file.Path actual,
                                  java.nio.charset.Charset charset,
                                  java.lang.String diffs)
    • Method Detail

      • shouldHaveContent

        public static ErrorMessageFactory shouldHaveContent​(java.io.File actual,
                                                            java.nio.charset.Charset charset,
                                                            java.util.List<Delta<java.lang.String>> diffs)
        Creates a new ShouldHaveContent.
        Parameters:
        actual - the actual file in the failed assertion.
        charset - the charset that was used to read the file.
        diffs - the differences between actual and the expected text that was provided in the assertion.
        Returns:
        the created ErrorMessageFactory.
      • shouldHaveContent

        public static ErrorMessageFactory shouldHaveContent​(java.nio.file.Path actual,
                                                            java.nio.charset.Charset charset,
                                                            java.util.List<Delta<java.lang.String>> diffs)
        Creates a new ShouldHaveContent.
        Parameters:
        actual - the actual path in the failed assertion.
        charset - the charset that was used to read the the path.
        diffs - the differences between actual and the expected text that was provided in the assertion.
        Returns:
        the created ErrorMessageFactory.