

@httpretty.activate
def test_http_example(self):
    ' The template formula should grab a template via http and save it '
    TEST_URI = 'http://testme.com/test.txt'
    httpretty.register_uri(httpretty.GET, TEST_URI, body=SIMPLE_TEMPLATE)
    self.environment.run_feature('http_example', 'sync')
    out_file = os.path.join(TEST_URI.temp_dir, 'out.txt')
    assert os.path.exists(out_file)
    assert (open(out_file).read() == SIMPLE_TEMPLATE)

dataset/ETHPy150Open toumorokoshi/sprinter/sprinter/formula/tests/test_template.py TestUnpackFormula.test_http_example/VarMisuse@55/111 `self`->`TEST_URI`