Archived
1
0
Commit Graph

16 Commits

Author SHA1 Message Date
kotborealis
f61ec4a41c
add CLI argument --disable-workspace-trust (#5638)
Add CLI flag to disable workspace trust feature, as
described in documentation:
https://code.visualstudio.com/docs/editor/workspace-trust

Add test for workspace trust argument.
2022-10-13 19:57:04 +00:00
Joe Previte
f9bfd58cf4
refactor: drop db migration patch (#5519)
* refactor: remove database migration patch & test

Drop migration code since it's been 6 months since 4.0.2 and we no
longer need this.

See: https://github.com/coder/code-server/issues/5482#issuecomment-1222608635

* chore: refresh patches
2022-08-30 23:14:21 +00:00
Joe Previte
f178f0400b
feat(e2e): add support running behind proxy (#5348)
* docs: update maintaining

* chore(e2e): add maxFailures to playwright

* fix(ci): skip submodule in e2e job

We don't need the submodules for the e2e job. This will speed up the
checkout step.

* feat(ci): add test-e2e-proxy job

This adds a new job to CI to run our tests behind Caddy and simulate
code-server running against a reverse-proxy.

* refactor: make e2e work with reverse proxy

This refactors the e2e test in a couple ways:
- remove setting cookie in localStorage (instead we pass --auth none)
- refactor address() method to account for reverse proxy logic

* Update test/e2e/models/CodeServer.ts

* Update test/playwright.config.ts

* Update test/utils/constants.ts

Co-authored-by: Asher <ash@coder.com>

* Update test/utils/helpers.ts

Co-authored-by: Asher <ash@coder.com>

Co-authored-by: Asher <ash@coder.com>
2022-08-09 18:24:37 +00:00
Joe Previte
03e0bdac03
chore: update vscode to 1.64 (#4902)
* chore: update vscode server files

* chore: update code to 1.64

* refactor: clean up code in constants.ts

* chore: keep package.json vscode cache

* fixup!: formatting

* feat(ci): add VSCODE_CACHE_VERSION

* fix(ci): add package.json for e2e tests

* fix: TS errors

* refactor: remove isConnected e2e tests
2022-03-09 14:28:52 -07:00
Asher
b61a8addcf
feat: migrate state to new database name (#4938)
* Merge setup and navigate functions

Whenever we navigate we probably want to make sure the editor is ready
so might as well just have one function.

* Add customizable entry and workspace directory

* Add test for state db migration

* Update Code

This contains the state migrations.
2022-03-03 12:32:43 -06:00
Asher
0e78a147b6
feat: github-auth flag (#4926)
* feat: github-auth flag

This will allow injecting credentials into code-server if you already
have them.

* Update Code

Contains the GitHub auth changes.

* Add e2e test for GitHub token
2022-03-02 14:02:51 -06:00
Asher
f9402a6318
fix: state collision (#4881)
* Add helper for navigating the quick picker

This has problems similar to the menu except instead of closing it gets
re-created which interrupts the hover call and causes the test to fail.
Now it will keep trying just like the menu.

* Add a test for opening a file

* Add test for colliding state

* Update VS Code

This contains the colliding state fix.
2022-02-22 12:43:13 -06:00
Joe Previte
e3e9f052c4
fix: wrap socket in proxy before passing to vscode (#4840)
* chore: add ipc hook to e2e script

* refactor: allow codeServerArgs in e2e tests

* feat: add --cert e2e extension test

* fix: wrap websocket in proxy

* fixup: remvoe ignoreHTTPSErrors

* fixup: make codeServerArgs readonly

* fixup! add back ignoreHTTPSErrors
2022-02-15 14:51:42 -07:00
Asher
f2fa7701a9
Centralize credential handling
My thinking is that this may reduce the cognitive overhead for
developers writing new test suites.

This also allows us to perform different setup steps (like ensuring the
editor is visible when authenticated).
2021-06-29 12:06:45 -05:00
Asher
da4de439e0
Spawn a code-server instance for each test suite
This uses the current dev build by default but can be overidden with
CODE_SERVER_TEST_ENTRY (for example to test a release or some other
version).

Each instance has a separate state directory. This should make
parallelization work.

This also means you are no longer required to specify the password and
address yourself (or the extension directory once we add a test
extension). `yarn test:e2e` should just work as-is.

Lastly, it means the tests are no longer subject to yarn watch randomly
restarting.
2021-06-29 12:06:38 -05:00
Max Schmitt
dbb34ad710 chore: upgrade to Playwright 1.12 with its new test-runner 2021-06-10 15:09:38 +02:00
Joe Previte
cde30579c4
refactor: change to reloadUntilEditorIsReady 2021-04-30 13:44:16 -07:00
Joe Previte
2cb499385a
feat: add isConnected method to CodeServer model 2021-04-30 13:36:46 -07:00
Joe Previte
b0ecff338f
refactor: globalSetup to use CodeServer model 2021-04-23 14:35:33 -07:00
Joe Previte
cc99fddf24
feat: add test for terminal echo to file 2021-04-23 14:35:32 -07:00
Joe Previte
2665a4f61b
feat: add CodeServer page object for e2e tests 2021-04-23 14:35:31 -07:00