Richard Hansen
f40d285109
tests: Refine contentcollector tests
2021-11-21 04:11:41 -05:00
Richard Hansen
263105d185
tests: Remove overly aggressive timeouts
2021-11-13 03:05:38 -05:00
Richard Hansen
3c6aef11bd
lint: Add 'use strict';
2021-11-13 03:02:40 -05:00
Richard Hansen
26675c5019
chat: New chatNewMessage
server-side hook
2021-11-01 01:54:29 -04:00
Richard Hansen
23a98e5946
tests: Refactor waitForSocketEvent()
to improve readability
2021-11-01 01:54:29 -04:00
Richard Hansen
3132235f2c
tests: Rename getSocketEvent()
to waitForSocketEvent()
2021-11-01 01:54:29 -04:00
Richard Hansen
65bd597053
tests: Move socket.io connection helpers to common.js
2021-11-01 01:54:28 -04:00
Richard Hansen
bea57ff249
tests: Use logger
variable for consistency
2021-11-01 01:54:28 -04:00
Richard Hansen
d36a37d666
PadMessageHandler: Delete unnecessary protocolVersion
...
We can assume that the client code is always in sync with what the
server expects.
2021-10-30 03:06:57 -04:00
webzwo0i
63de249236
tests: do not re-add identical text with setText
2021-10-29 02:29:45 -04:00
Richard Hansen
0ea6f1518c
tests: Remove overly agressive timeouts
2021-10-07 20:31:54 -04:00
Richard Hansen
2155e216a6
tests: Remove overly agressive timeouts
2021-10-07 19:53:03 -04:00
Richard Hansen
e8514db365
tests: Replace manual checks with assert
2021-10-03 20:23:30 -04:00
Richard Hansen
72b12bc97b
tests: Slight backend test reorganization
...
* Delete some useless uses of `describe()`
* Combine some dependent tests
* Rename some tests to avoid duplicate names
2021-10-03 20:06:33 -04:00
Richard Hansen
dd37251da4
tests: Promisify some backend tests
2021-10-03 19:25:50 -04:00
Richard Hansen
39a971e3b9
tests: Remove overly aggressive timeouts
2021-10-03 19:25:50 -04:00
Richard Hansen
70c16bb1b5
tests: Check import of export of read-only pad ID
2021-09-15 18:32:06 -04:00
John McLear
b683dc300d
tests: Check for leak of read-write pad ID when exporting
2021-09-15 18:32:06 -04:00
Richard Hansen
0f5a4bd1f8
tests: Restructure read-only pad export tests
...
This also adds coverage for `.etherpad` exports.
2021-09-15 18:32:06 -04:00
Richard Hansen
bc9cdd6957
SocketIORouter: Add acknowledgement support
2021-09-06 14:45:26 -04:00
Richard Hansen
9f9adb369b
SocketIORouter: Don't crash if message handler throws
2021-09-06 14:45:26 -04:00
Richard Hansen
320e5c1109
SocketIORouter: Add unit tests
2021-09-06 14:45:26 -04:00
Richard Hansen
348bc0c269
tests: Delete overly aggressive timeouts
...
See https://github.com/ether/etherpad-lite/issues/4988 for rationale.
2021-08-30 02:02:37 -04:00
Richard Hansen
c816c20bc7
HTML import: Replace cheerio with jsdom to simplify contentcollector
...
Cheerio provides jQuery-like objects but they wrap DOM Node-like
objects that are not 100% API compatible with the DOM spec. Because of
this, contentcollector, which is used in browsers and in Node.js
during HTML import, has until now needed to support two different
APIs. This commit modifies HTML import to use jsdom instead of cheerio
and simplifies contentcollector.
2021-08-12 13:53:23 -04:00
Richard Hansen
6c2f31a5cb
tests: Add tests for settings.json
parsing
2021-06-06 14:00:52 -04:00
Richard Hansen
0d9476529e
sanitizePathname: Move to separate module to facilitate reuse
2021-06-03 15:10:21 -04:00
Richard Hansen
926da57e34
Minify: Refine sanitizePathname
to avoid pathname traversal
2021-06-03 15:10:21 -04:00
Richard Hansen
59c03bde20
lint: Re-run eslint --fix
2021-05-12 11:26:35 +02:00
Richard Hansen
ea8846154f
favicon: Redo favicon customization
2021-04-20 13:33:55 -04:00
Richard Hansen
92e0bff80c
favicon: Refactor handler and add tests
2021-04-20 13:33:55 -04:00
webzwo0i
20c512c8a9
test for await db.set in createAuthor
2021-04-20 11:27:43 -04:00
Richard Hansen
f63610bb12
tests: Test access bypass via read-only pad ID
2021-04-12 22:51:06 -04:00
pcworld
0d33793908
tests: readonly pastes must be readable+exportable with authentication
...
readonly paste links should be readable even if authentication is turned
on, as long as the user provides valid login data.
This test currently fails.
Also test that readonly paste IDs can be exported under the same
condition, which currently succeeds.
2021-04-12 22:51:06 -04:00
John McLear
b80f5bdae8
bugfix/tests/scaling: Socket query test fix ( #4974 )
...
fix socketio test where res.req is not available.
2021-03-24 21:03:48 +00:00
John McLear
2b98b930d7
scaling: include padId in socketio query string
2021-03-24 16:07:11 +00:00
Richard Hansen
83f39289aa
import/export: On export error return 500 instead of crashing
2021-03-18 09:02:28 +00:00
Richard Hansen
fe1eceb6b5
tests: Use assert
to simplify import/export tests
2021-03-18 09:02:28 +00:00
Richard Hansen
98c42d6076
tests: Promisify import/export tests
2021-03-18 09:02:28 +00:00
Richard Hansen
ff50682412
tests: Increase import/export test timeouts
2021-03-18 09:02:28 +00:00
webzwo0i
377883db98
fix pads with spaces ( #4884 )
2021-02-27 22:34:43 -05:00
Richard Hansen
3a34db84e6
tests: Refine CachingMiddleware tests
...
* Lint functions
* Fix assignment of `settings.minify`
* Use a for loop to avoid copied code for the `minify = true` and
`minify = false` cases
* Put each resource fetch into its own test case
* Check for 200 status code
* Use `.expect()` to check header value
* Use `.expect(fn)` instead of `.then(fn)`
2021-02-27 14:03:09 +01:00
John McLear
0f16e518ff
api: drop JSONP ( #4835 )
...
* api: drop JSONP
* docs: drop JSONP
* tests: drop JSONP
* api: remove isValidJSONPName require
2021-02-22 09:10:02 +00:00
webzwo0i
14a9749b75
tests: add assert helper for supporting node 10.x
2021-02-22 03:36:12 -05:00
Richard Hansen
9633b98f92
tests: Delete unnecessary use of npm
package
2021-02-18 19:18:59 +00:00
John McLear
9fb2c640b9
tests: Microsoft Windows Server CI ( #4791 )
...
Due to a recent release that wasn't functioning properly this CI will help us catch the majority of Microsoft Node Quirks before they make it into a release.
2021-02-18 18:49:43 +00:00
Richard Hansen
7dae5e3db8
tests: Use the supertest agent from common.js
for backend tests
2021-02-16 21:13:35 -05:00
Richard Hansen
5a91cf1b49
tests: Disable rate limiting for backend tests
2021-02-16 21:13:35 -05:00
Richard Hansen
4ae8fbc40d
tests: Increase importexportGetPost.js
timeouts
...
The tests were timing out on my machine.
2021-02-16 21:13:35 -05:00
Richard Hansen
3d2f77f75d
lint: Fix ESLint errors in backend tests
2021-02-16 21:13:35 -05:00
Richard Hansen
b711ff6acf
import: Ajaxify pad import
...
This eliminates an inline script (good for Content Security Policy)
and improves the user experience.
2021-02-14 08:35:38 +00:00