Always turn off the power prior to working on a junction box. You don't want to be the unlucky person who comes across a highly dangerous hot wire.
Also, don't just guess which breaker switch controls the room you're working in. Instead, hit the main breaker so that there will be no question at all about the fact that the power is turned off.
(Really, in comparison, it's a small inconvenience to have to reset digital clocks to avoid a potentially fatal outcome.)
Finally, punch out a hole to provide a path for the wires to enter the box. Use a cable clamp to secure the ROMEX wiring that comes into the box, and cap wires inside the box with wire nuts. If you have difficulty twisting the wires together, use needle-nose pliers to twist black to black and white to white, before attaching the wire nut. Then, ground the box securely.