def test_verify(self): url = absolutify( reverse('receipt.test.verify', kwargs={'status': 'expired'})) receipt = create_test_receipt('http://foo', 'expired') req = RawRequestFactory().post(url, receipt) res = devhub_verify(req, 'expired') eq_(json.loads(res.content)['status'], 'expired')
def test_verify(self): url = absolutify(reverse('receipt.test.verify', kwargs={'status': 'expired'})) receipt = create_test_receipt('http://foo', 'expired') req = RawRequestFactory().post(url, receipt) res = devhub_verify(req, 'expired') eq_(json.loads(res.content)['status'], 'expired')
def test_verify_fails(self): req = RawRequestFactory().post('/', '') res = devhub_verify(req, 'expired') eq_(json.loads(res.content)['status'], 'invalid')
def test_verify(self): url = absolutify(reverse("receipt.test.verify", kwargs={"status": "expired"})) receipt = create_test_receipt("http://foo", "expired") req = RawRequestFactory().post(url, receipt) res = devhub_verify(req, "expired") eq_(json.loads(res.content)["status"], "expired")
def test_verify_fails(self): req = RawRequestFactory().post("/", "") res = devhub_verify(req, "expired") eq_(json.loads(res.content)["status"], "invalid")