A test fixture sets up the system under test (SUT) for the software testing process by initializing it (configuration and/or data) satisfying any preconditions the system may have.
Example: initialize a database with known parameters before running a test.
This allows for tests to be repeatable, which is one of the key features of an effective test framework.
In a non-software context, such as circuit boards, a test fixture is a setup or another device designed to hold the device under test (DUT) in place and allow it to be tested.
References:
https://en.wikipedia.org/wiki/Test_fixture