'upload_template() should work OK with file and directory destinations'

@server()
def test_upload_template_handles_file_destination(self):

    template = self.mkfile('template.txt', '%(varname)s')
    local = self.path('result.txt')
    remote = '/configfile.txt'
    var = 'foobar'
    with hide('everything'):
        upload_template(template, remote, {'varname': var})
        get(remote, local)
    eq_contents(local, var)
