I'm confused on what command to use on a cisco switch where if the power is unplugged from the switch, I lose the configuration I saved and it reverts back to the previous config. I've been researching through commands like write memory and copy running-config startup-config but they both state that it overwrites the start up config file meaning it's permanent? Is this correct? I want to test my new config when there's power but be able to revert back to the old config if I pull the power. What's the command for that?
wr mem and copy run start both replace the startup configuration. If you don't want to replace the startup config, (obviously) don't save to the startup config. copy run somwhere-else. There are many options for "somewhere-else".
The running configuration is what you're changing with conf t. Those changes do not persist if you don't take steps to save them.