Fixed octal representations of mode in CopyAction.

The mode is given as a string, but os.chmod requires that the string
undergoes octal integer conversion and is passed in as an int. This also
requires converting back to the octal string when doing tests and
printing.
Added early CopyAction tests.