i want to assert in python that the object has no particular field.
i have an object like below,
output = {
'username': 'user',
'hidden_fields': {
'name': 'name1',
}
}
but sometimes this hidden_fields property might not be there. so the object is like so,
output = {
'username': 'user'
}
now how can i assert that output object has no property hidden_fields.
i am new to python. could someone help me with this. thanks.