Partially addresses #47424.
Had to make changes to spec files because
stubbing methods on frozen objects is a mess
in RSpec and leads to failures:
https://github.com/rspec/rspec-mocks/issues/1190
Instead of renaming existing storage directories to a timestamped
format, create a timestamped directory in a temporary location and move
the individual files and folders inside storage directories to it. This
helps us with nested storage directories.