def test_get_value_heroku_token(self):

        with mock.patch("werckercli.config.puts", mock.Mock()) as puts:
            # reload(config)
            result = config.get_value(config.VALUE_HEROKU_TOKEN)

            self.assertEqual(puts.call_count, 1)
            calls = puts.call_args_list
            self.assertTrue('0600' in calls[0][0][0])
        self.assertEqual(result, '1234567890123456789912345678901234567890')

        os.environ.pop('HOME')

        self.assertRaises(IOError, config.get_value, config.VALUE_HEROKU_TOKEN)
dataset/ETHPy150Open wercker/wercker-cli/werckercli/tests/test_config.py/GetValueUrlTests.test_get_value_heroku_token/original