Skip to content
This repository has been archived by the owner on Jan 25, 2022. It is now read-only.

Commit

Permalink
Switch to kinto 4 core testing
Browse files Browse the repository at this point in the history
  • Loading branch information
leplatrem committed Nov 7, 2016
1 parent 8acdd67 commit ed50896
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions tests/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import os

import webtest
from kinto.tests.core import support as core_support
from kinto.core.testing import get_request_class
from kinto.core import utils as core_utils


Expand Down Expand Up @@ -34,7 +34,7 @@ def setUp(self):
def make_app(self):
curdir = os.path.dirname(os.path.realpath(__file__))
app = webtest.TestApp("config:%s" % self.config, relative_to=curdir)
app.RequestClass = core_support.get_request_class(prefix="v1")
app.RequestClass = get_request_class(prefix="v1")
return app

def create_collection(self, bucket_id, collection_id):
Expand Down
8 changes: 4 additions & 4 deletions tests/test_changes.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from kinto.tests.core.support import unittest
import unittest

from kinto_changes import __version__ as changes_version
from . import BaseWebTest, get_user_headers
Expand Down Expand Up @@ -158,9 +158,9 @@ def test_changes_bucket_and_collection_can_be_specified_in_settings(self):
self.assertEquals(len(resp.json['data']), 1)

def test_changes_records_permissions_can_be_specified_in_settings(self):
resp = self.app.get('/buckets/mozilla/collections/updates',
headers=self.headers)
self.assertIn('user:natim', resp.json['permissions']['read'])
self.app.get('/buckets/mozilla/collections/updates',
headers=self.headers,
status=200)

def test_changes_records_are_not_readable_for_unauthorized(self):
headers = self.headers.copy()
Expand Down

0 comments on commit ed50896

Please sign in to comment.