'Check whether sensitive variables are properly stripped from stack-trace
messages.'

def test_stacktrace(self, *args, **kwargs):

    data = get_stack_trace_data_real()
    proc = SanitizePasswordsProcessor(Mock())
    result = proc.process(data)
    self.assertTrue(('exception' in result))
    exception = result['exception']
    self.assertTrue(('values' in exception))
    values = exception['values']
    stack = values[(-1)]['stacktrace']
    self.assertTrue(('frames' in stack))
    self.assertEquals(len(stack['frames']), 2)
    frame = stack['frames'][1]
    self.assertTrue(('vars' in frame))
    self._check_vars_sanitized(frame['vars'], proc)
