def dynatemplate(kw, method, action, class_):
    """builds a simplistic template string, see  dTemplate()  - used for tests -"""
    temp = ['<form method="{0}" action="{1}">'.format(method, action)]
    for i in kw:
        temp.append(
            '<div>{{{{ form.{0}.label }}}}: {{{{ form.{0}(class="{1}") }}}}</div>'
            .format(i, class_))
    temp.append('</form>')
    return '\n'.join(temp)
