add discard_original_filename upload flag. Formatting in tests