mahmoud / glom

☄️ Python's nested data operator (and CLI), for all your declarative restructuring needs. Got data? Glom it! ☄️
https://glom.readthedocs.io
Other
1.88k stars 61 forks source link

Missing assert in test_mutation.py #269

Closed Sjord closed 10 months ago

Sjord commented 10 months ago

glom/glom/test/test_mutation.py at master · mahmoud/glom

def test_s_assign():
    '''
    check that assign works when storing things into S
    '''
    glom({}, (Assign(S['foo'], 'bar'), S['foo'])) == 'bar'

glom(...) == 'bar' should probably be assert glom(...) == 'bar'

mahmoud commented 10 months ago

Great catch, both here and #270. Now I'm wondering if there's a pytest plugin to warn when a test function doesn't perform a single assert :) Thanks!