Hold the fixture up to splice the wires. Usually the first wire splice will aid in supporting a small light, but have a helper assist with supporting a large, heavy fixture while making the connections. While still supporting the weight, attach the base to the mounting strap with the screws and tighten the base to the ceiling.
In this example a new wall receptacle can be installed using an existing receptacle in an adjacent room. This can often be the easiest and most likely solution to access a source for a new receptacle or a switch to a new light fixture. Set the new outlet box in the same wall space as the existing one to simplify running the cable.
After cutting the hole, put the 2x4 between the joists again and set it so the outlet box sits flush with the finished ceiling surface. Have a helper hold a board over the outlet hole to support the box and keep it at the proper level while securing it in place with two, 3 inch deck screws through each joist. If needed, metal L-brackets may be added at the corners for more support.
Thread the connector clockwise onto the twisted wires, being sure no bare copper is exposed at the bottom. Pull gently on the connector to be sure it’s secure. You can wrap electrical tape around the wires and cap for extra security or just push the splices into the back of the box and attach the cover plate.