module HexaPDF::TestUtils

Contains various helper methods for testing HexaPDF

Public Instance Methods

assert_method_invoked(object, name, *expected_values, check_block: false) { || ... }

Asserts that the method name of object gets invoked with the expected_values when executing the block. expected_values should contain arrays of arguments, one array for each invocation of the method.

assert_operators(content, operators, only_names: false, range: 0..-1)

Asserts that the content string contains the operators.

collector(source)

Collects the result from the HexaPDF::Filter source into a binary string.

feeder(string, len = string.length)

Creates a fiber that yields the given string in len length parts.