def test_2(**kwds):

    from histogram.DictAttributeCont import AttributeCont
    attCont = AttributeCont()

    attCont.setAttribute('name', 'timmah!')

    passed = True
    name = attCont.getAttribute('name')
    if name != 'timmah!':
        passed = False
        log("value of 'name' attribute ({0!s}) was incorrect".format(name))

    return passed
def test_2( **kwds):

    from histogram.DictAttributeCont import AttributeCont
    attCont = AttributeCont()

    attCont.setAttribute( 'name', 'timmah!')

    passed = True
    name = attCont.getAttribute('name')
    if name != 'timmah!':
        passed = False
        log("value of 'name' attribute (%s) was incorrect" % name)  
        
    return passed
def test_1(**kwds):

    from histogram.DictAttributeCont import AttributeCont
    attCont = AttributeCont()

    attCont.setAttribute('name', 'timmah!')

    passed = True
    attDict = attCont._attributes
    try:
        name = attDict['name']
        if name != 'timmah!':
            passed = False
            log("value of 'name' attribute ({0!s}) was incorrect".format(name))
    except KeyError:
        passed = False
        log("did not store 'name' as a key")

    return passed
def test_1( **kwds):

    from histogram.DictAttributeCont import AttributeCont
    attCont = AttributeCont()

    attCont.setAttribute( 'name', 'timmah!')

    passed = True
    attDict = attCont._attributes
    try:
        name = attDict['name']
        if name != 'timmah!':
            passed = False
            log("value of 'name' attribute (%s) was incorrect" % name)
    except KeyError:
        passed = False
        log("did not store 'name' as a key")
        
    return passed
def test_3(**kwds):
    from histogram.DictAttributeCont import AttributeCont
    attCont = AttributeCont()

    attCont.setAttribute('name', 'timmah!')
    attCont.setAttribute('unit', 'tons')

    passed = True
    attList = ['name', 'unit']
    acList = attCont.listAttributes()
    if acList != attList:
        passed = False
        log("listAtts() returned {0!s}, should have been {1!s}".format(
            acList, attList))

    return passed
def test_3( **kwds):
    from histogram.DictAttributeCont import AttributeCont
    attCont = AttributeCont()

    attCont.setAttribute( 'name', 'timmah!')
    attCont.setAttribute( 'unit', 'tons')

    passed = True
    attList = ['name', 'unit']
    acList = attCont.listAttributes()
    if acList != attList:
        passed = False
        log("listAtts() returned %s, should have been %s" %(acList, attList))
        
    return passed
def test_0(**kwds):

    from histogram.DictAttributeCont import AttributeCont
    attCont = AttributeCont()
    return True