def test_expand_shortened_link(self):
        link = Url(self.key, self.test_url)
        db.session.add(link)
        db.session.commit()
        # Get /<key>
        r = self.client.get(self.key)
        self.assertEqual(r.status_code, 302)
        # Redirect to expanded link
        assert self.test_url and r.data in "redirected"
dataset/ETHPy150Open itsnauman/shrt/test_shrt.py/TestShrt.test_expand_shortened_link/swapped operands of `in`