Lines Matching refs:example
11 and then sets *expectations* for what should happen. For example:
24 In the above example, ``example_test_success`` always passes because it does
36 logged. For example:
46 In the above example, ``add_test_basic`` makes a number of assertions about the
65 For example, if we want to rigorously test the ``add`` function above, create
97 terminates the test case if the condition is not satisfied. For example:
115 In this example, we need to be able to allocate an array to test the ``sort()``
163 suite and/or every test case. For example:
175 .name = "example",
184 In the above example, the test suite ``example_test_suite`` would first run
213 or hardware specific. For example, we might want to test code that really
227 .. TODO(brendanhiggins@google.com): Add an actual example of an architecture-
268 example:
296 In this example, computing the pointer to the child from the pointer to the
309 example, implementing a fake EEPROM that stores the "contents" in an
463 for example: testing a hash function.
466 For example, to test ``sha1sum(1)``, we can write:
486 helper macro variation, for example:
519 * For example, see ``fs/ext4/inode-test.c``.
523 * For example: if we want to test ``sha256sum``, we could add a ``sha256``
591 For example:
610 example:
625 Similar to as shown above, we can add test-specific logic. For example:
645 is helpful, for example, when providing a fake implementation of a function, or
655 The example below uses this to implement a "mock" implementation of a function, ``foo``:
689 In this example, we are using the ``priv`` member of ``struct kunit`` as a way
696 flexibility as a ``priv`` member, but also, for example, allowing helper
706 For example, we have an option to enable some extra debug checks on some data