Commit Graph

10670 Commits

Author SHA1 Message Date
Itamar Turner-Trauring
21e3b355ec Finish porting to Python 3. 2020-09-25 14:03:25 -04:00
Itamar Turner-Trauring
d19ae1e511 Apparently __remote_name__ needs to be a native string. 2020-09-25 14:00:18 -04:00
Sajith Sasidharan
65f206e39b
Merge pull request #816 from sajith/3427.return-error-page-from-unlinked
Return ErrorPage from unlinked

Fixes ticket:3427
2020-09-25 13:30:02 -04:00
Itamar Turner-Trauring
565c48045e Closer to passing tests. 2020-09-25 13:28:59 -04:00
Itamar Turner-Trauring
d8c9affccb Bunch more places that need to be bytes for protocol backwards compatibility. 2020-09-25 13:28:49 -04:00
Ross Patterson
b306475370 test(runner): Save iteration time, fail early
The `codechecks` commands run fastest and show the most obvious errors so no need to
wait for the longer-running other tests first.
2020-09-25 10:22:04 -07:00
Ross Patterson
2ef422e064 test(vcs): Add a VCS push hook to run tests
Personally, I can't stand working without a VCS hook anymore.  It saves me so much time
in context switches from revisiting and revising PRs when I see that the CI run is red.
Much better to fail before I push so I can revise while the relevant changes are fresh
in my head.

In order to start using this, one has to run `$ make build` first.  Should I add that
and make other documentation changes in the wiki related to my changes in this PR?
2020-09-25 10:18:11 -07:00
Itamar Turner-Trauring
9e5d5b5f8b Remove typo. 2020-09-25 13:16:47 -04:00
Itamar Turner-Trauring
47aa724c42 Merge remote-tracking branch 'origin/master' into 3439.test-download-python-3 2020-09-25 13:16:12 -04:00
Itamar Turner-Trauring
5e52691433
Merge pull request #827 from tahoe-lafs/3437.test-filenode-python-3
Port test_filenode.py to Python 3

Fixes ticket:3437
2020-09-25 13:15:30 -04:00
Sajith Sasidharan
569ac924ec
Merge pull request #825 from sajith/3436.remove-web-common-getxmlfile
Remove unused web.common.getxmlfile()

Fixes ticket:3436
2020-09-25 12:54:51 -04:00
Itamar Turner-Trauring
5d9a1a5ab5 Some progress towards passing tests. 2020-09-25 11:46:31 -04:00
Jean-Paul Calderone
8cdf5cbf26 unused import 2020-09-25 11:09:55 -04:00
Jean-Paul Calderone
2314a9f2f6 add a test for referrer-policy 2020-09-25 11:06:54 -04:00
Jean-Paul Calderone
3dddcd6f62 Remove assertions about Twisted Web's quoting behavior
It quotes stuff.  It's cool.  BeautifulSoup even looks at it for us and will
tell us if something is amiss.
2020-09-25 09:44:04 -04:00
Jean-Paul Calderone
dc15f19ee0 Merge remote-tracking branch 'origin/master' into 3382.remove-multi-format-page 2020-09-25 09:37:02 -04:00
Jean-Paul Calderone
44cc42351f remove duplicate request 2020-09-25 09:32:06 -04:00
Jean-Paul Calderone
05def35c26 nicer cleanup plus a comment 2020-09-25 09:31:57 -04:00
Jean-Paul Calderone
b218b5426b docstrings 2020-09-25 09:31:53 -04:00
Jean-Paul Calderone
f13390d3d4 news fragment 2020-09-25 09:26:56 -04:00
Jean-Paul Calderone
dcb834c7a6 Merge remote-tracking branch 'origin/master' into 3438.test_introweb 2020-09-25 09:26:34 -04:00
Itamar Turner-Trauring
51709d5562
Merge pull request #817 from tahoe-lafs/3430-test-upload-python-3
Port test_upload.py to Python 3

Fixes ticket:3430
2020-09-24 16:57:38 -04:00
Ross Patterson
ce20ac6a74 test(coverage): Avoid redundant test runs
There's no need in almost all cases to run the tests both under the coverage collector
and without it.  This fixes the default set of tests to avoid that.  Specifically, don't
run tests under the coverage collector by default for all environments since we don't
capture any error or failure conditions on reporting coverage anyways.
2020-09-24 12:38:42 -07:00
Jean-Paul Calderone
0f8cb7aedf
Merge pull request #828 from tahoe-lafs/3440.render-helper
Make the render test helper generally useful

Fixes: ticket:3440
2020-09-24 15:29:31 -04:00
Ross Patterson
a8ef046b50 build(news): Fix missing ChangeLog entry 2020-09-24 11:44:38 -07:00
Ross Patterson
430881be15 test(py3): Capture how to run all tests under py3
Useful to review common errors under Python 3 as opposed to module-by-module.
2020-09-24 11:37:58 -07:00
Ross Patterson
92de966c91 test(runner): Use checked out source for local tests
TL;DR: Capture how to use real source file paths for local development.

It can be useful to run the tests against the currently checked out Python source files.
Changes are reflected immediately.  Source file paths in Tracebacks (and other things
that print the file path for Python modules) are to the actual checked out source and
can be copied and pasted or used by tools that expect real paths.

OTOH, testing against a real Python package install into a virtualenv done from a real
source distribution can expose rare but very confusing issues.

So doing both is valuable.  Most typically, the former is useful for local development
and the latter is most appropriate in CI.
2020-09-24 11:37:49 -07:00
Ross Patterson
1593ff5c52 test(coverage): Include human-readable coverage report
While the XML coverage report is useful for consumption by other tools, such as
currently by codecov.io in CI, it's not very useful for humans reviewing the immediate
impact of changes on coverage during local development or while monitoring CI output.  I
don't think running the text report takes much more time so I don't see a downside
here.
2020-09-24 11:37:37 -07:00
Ross Patterson
0c533733f0 test(runner): Match contributor guidelines from wiki
The [Patches Trac Wiki page](https://tahoe-lafs.org/trac/tahoe-lafs/wiki/Patches) says
that users should run the `codechecks` tox environment, so this change runs it be
default as the full tox test suite eliminating the extra step.
2020-09-24 11:36:58 -07:00
Jean-Paul Calderone
1c5f4e2bf0 Compatible with the interface I used in test_web.py 2020-09-24 11:08:18 -04:00
Jean-Paul Calderone
16ab1690de rewrite _test_introweb part of SystemTest as its own test suite 2020-09-24 11:08:18 -04:00
Jean-Paul Calderone
e981fea007 make FakeCanary more realistic 2020-09-24 11:08:18 -04:00
Itamar Turner-Trauring
4784d2c3a8 News fragment. 2020-09-24 11:06:47 -04:00
Itamar Turner-Trauring
26f28f341f Finish port to Python 3. 2020-09-24 11:03:42 -04:00
Itamar Turner-Trauring
8167a9fda6 All tests pass on Python 3. 2020-09-24 11:01:35 -04:00
Itamar Turner-Trauring
5cd00d6f2e And even more tests passing in Python 3. 2020-09-24 10:55:47 -04:00
Itamar Turner-Trauring
37bc022edc Even more tests passing on Python 3. 2020-09-24 10:46:10 -04:00
Jean-Paul Calderone
f1bcf4eb07 remove unused imports 2020-09-24 10:42:57 -04:00
Itamar Turner-Trauring
d9036e83b2 More tests passing on Python 3. 2020-09-24 10:39:06 -04:00
Itamar Turner-Trauring
e7fe2f0a3f It imports on Python 3. 2020-09-24 10:32:41 -04:00
Jean-Paul Calderone
67adb9303b news fragment 2020-09-24 10:23:34 -04:00
Jean-Paul Calderone
e7101b1711 Turn exceptions into error pages like Nevow does 2020-09-24 10:23:05 -04:00
Jean-Paul Calderone
34bade4091 Use the newly introduced helper instead of our own internal thing 2020-09-24 10:22:07 -04:00
Jean-Paul Calderone
ed049da34f Add a helper that can render a Page or a Resource 2020-09-24 10:21:18 -04:00
Chad Whitacre
06cd64c891 De-lint 2020-09-23 21:41:23 -04:00
Chad Whitacre
3ae927eab9 Respond to review
- Preserve int division
- Dial back the __future__ imports
2020-09-23 21:18:24 -04:00
Itamar Turner-Trauring
5a2728fa05 Finish port to Python 3. 2020-09-23 15:56:09 -04:00
Itamar Turner-Trauring
5790ae8ece Tests pass on Python 3. 2020-09-23 15:53:13 -04:00
Itamar Turner-Trauring
d8c5e8b44f News file. 2020-09-23 15:39:19 -04:00
Itamar Turner-Trauring
5fbbb5be0f News file. 2020-09-23 15:21:47 -04:00