Skip to content

Commit

Permalink
12.0 test ApiTestBase
Browse files Browse the repository at this point in the history
  • Loading branch information
SkywalkerSpace committed May 15, 2024
1 parent 7bfc7ba commit 897b615
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
1 change: 1 addition & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,3 +40,4 @@ jobs:
cd $GITHUB_WORKSPACE
export CCNET_CONF_DIR=/tmp/ccnet SEAFILE_CONF_DIR=/tmp/seafile-data TRAVIS=1
if ./tests/test_seahub_changes.sh; then ./tests/seahubtests.sh init && ./tests/seahubtests.sh runserver && ./tests/seahubtests.sh test; else true; fi
cat /tmp/logs/seahub.access.log
8 changes: 4 additions & 4 deletions tests/api/apitestbase.py
Original file line number Diff line number Diff line change
Expand Up @@ -84,12 +84,12 @@ def _req(cls, method, *args, **kwargs):
if expected is not None:
if hasattr(expected, '__iter__'):
assert_in(resp.status_code, expected,
"Expected http status in %s, received %s" % (expected,
resp.status_code))
"Expected http status in %s, received %s, %s, %s" % (expected,
resp.status_code, resp.text, args))
else:
assert_equal(resp.status_code, expected,
"Expected http status %s, received %s" % (expected,
resp.status_code))
"Expected http status %s, received %s, %s, %s" % (expected,
resp.status_code, resp.text, args))
return resp

def assertHasLen(self, lst, length):
Expand Down

0 comments on commit 897b615

Please sign in to comment.