Commit Graph

28 Commits

Author SHA1 Message Date
Alan Guo Xiang Tan 6e4e95ef1a
DEV: Skip core features specs on stable (#269)
The shared example is not available in stable yet
2025-04-23 10:52:30 +08:00
Loïc Guitaut d5f5e93db1
DEV: Add system spec to check core features are working fine (#267) 2025-04-09 14:58:07 +02:00
Jarek Radosz ea174f7e36
DEV: Clean up the code (#245)
gjs, helper invocation case, typos, latest license template, unnecessary tracking, concatClass, unnecessary service injection, new imports, whitespace, pure function helper, htmlSafe calling convention, this. in template, unused vars in ruby, update linting, qunit-dom
2024-10-23 11:21:22 +02:00
Ella E. 06cc8dba9d
UX: Adjust table to be responsive on mobile (#244)
* UX: Apply core admin table classes to be visually responsive; styling tweaks

* DEV: update spec to use new classes

* fix failing tests
2024-10-22 16:45:36 -06:00
Alan Guo Xiang Tan 30f2300ba8
DEV: Skip tests that shouldn't be run with `if` instead of `pending` (#239)
This speeds up running of this test file by around 10 seconds for me
locally which is a 20% improvement.
2024-09-11 15:11:20 +08:00
Bianca Nenciu 957867798e
DEV: Optimize specs (#238)
Git repositories will be initialized less often and then copied for each
spec. This reduces the calls to 'git' and the total execution time of
the specs.
2024-09-06 14:45:34 +08:00
Bianca Nenciu 3a43aa6be7
DEV: Speed up /admin/docker/repos.json spec (#237)
Requesting /admin/docker/repos.json with a lot of plugins installed can
take a lot of time because of the large number of calls to the 'git'
CLI that are used to retrieve various information about the plugin
(eg. branch, latest commit, remote URL, etc).

This is not a problem in production because of memoization and the
much lower number of installed plugins, but it is a problem in test
environment where specs requesting this page can take 10+ seconds with
~100 installed plugins.

This commit speeds up by stubbing the `find_all` method to return only
the first few repositories.
2024-09-04 13:58:00 +03:00
David Taylor c42a2e901d
DEV: Skip system spec (#227)
This is still failing in our core CI. Followup to fe25a76fe3
2024-07-12 12:07:03 +01:00
Alan Guo Xiang Tan c47c37e107
DEV: Print page's HTML at the end after test fails (#226)
This system spec is flaky and we are getting a blank page so I would
like to see what the HTML is. Previously printing of the page's HTML was
doing it too early such that the ember application has not even boot.
2024-07-11 14:17:02 +08:00
Alan Guo Xiang Tan f3eda0a1a9
DEV: Add debugging info to figure out why system test is failing on CI (#225) 2024-07-11 10:08:11 +08:00
Alan Guo Xiang Tan fe25a76fe3
DEV: Unskip system tests and avoid predicate matchers (#224)
RSpec predicate matchers provide poor output when tests fail.
This commit switches to Capybara RSpec matches so that we get more
debugging information as to why these tests are flaky...
2024-07-10 10:38:29 +08:00
Vinoth Kannan 32170dfa38
DEV: skip the flaky system tests (#223)
I'm unable to find why the tests are failing in the Discourse core repo's plugin tests workflow. These tests always pass in the plugin repo and my local dev environment.
2024-07-09 23:12:50 +05:30
Vinoth Kannan e29c6b1504
UX: improve UI of software update page & display more info. (#214)
This PR will refresh the software update page so that self-hosters can more easily understand the plugins they have installed and which plugins need updates, and so that they are able to quickly and easily update them (or update everything).

Co-authored-by: Martin Brennan <mjrbrennan@gmail.com>
2024-07-09 00:14:26 +05:30
Vinoth Kannan da4917770d
DEV: rename the "upgrade" route to "update" and change references. (#210)
This PR will rename the route "`/admin/upgrade`" to "`/admin/update`" and it will add a redirect for the old route.

Follow-up to the PR: https://github.com/discourse/docker_manager/pull/208
2024-04-03 21:10:13 +05:30
Jarek Radosz 7cb07ca0a0
DEV: Update linting (#198) 2023-12-13 21:16:57 +01:00
David Taylor 4a493543de
DEV: Support new discourse-compatibility format on old core (#186)
This introduces a fallback compatibility parser, identical to the one introduced in https://github.com/discourse/discourse/pull/22714

This will allow Docker Manager to parse new compatibility files, even when running on older Discourse instances. This is only intended as a temporary solution, and will be removed before the Discourse 3.2 release.
2023-07-25 14:31:27 +01:00
David Taylor eecf0af9a9
DEV: Silence git stderr output (#182)
The git stderr output was making test output very noisy (and was also polluting production stderr logs)
2023-05-03 10:41:02 +01:00
Gerhard Schlager cf9975ad56
FIX: Upgrading was broken when repo uses `master` branch (#180) 2023-04-20 18:24:14 +02:00
Gerhard Schlager 6293c3d948
FEATURE: Adds support for git tags (#177)
* FEATURE: Adds support for git tags

* Detects when the tracked branch has been deleted from `origin` and forces a rebuild on the command line
* Allows updating when a tag is tracked and the tag was moved to a new commit
* Improves support for shallow clones
* Works with partial clones
* Adds lots of specs for git commands and replaces the existing specs. All specs use real git repositories instead of mocks
2023-04-19 19:17:48 +02:00
Gerhard Schlager e90c8f55fc DEV: Apply syntax_tree formatting with config from core 2023-03-08 13:41:34 +01:00
Jarek Radosz dcad087190 DEV: Update specs 2023-02-16 14:09:33 +01:00
Jarek Radosz 4ab63aca32 DEV: Run stree 2023-02-16 14:09:33 +01:00
Robin Ward a27337faf2
FEATURE: Prefer `origin/main` over `origin/master` if it exists (#89)
This allows us to rename the main branch for plugin repos to
`origin/main` and docker_manager should continue to work.
2021-02-05 11:27:12 -05:00
Guo Xiang Tan 00617a1fb5 Add frozen string literal comment to files. 2019-05-13 11:16:32 +08:00
Robin Ward 8f6be9c592 SECURITY: Make sure a repo exists before acting on it
Also includes refactors to clean up linting / code, adds specs
and changes the usage pattern to something safer
2018-06-15 15:15:17 -04:00
Robin Ward f75ece9a95 Use our `AdminConstraint` to simplify auth 2018-06-15 13:15:34 -04:00
Guo Xiang Tan 1f686200bb Display a glyph for official plugins. 2018-04-25 12:20:06 +08:00
Guo Xiang Tan f117e28158 FIX: Redirect to login for anon user.
https://meta.discourse.org/t/link-to-upgrade-shows-500-error/70993/7
2017-10-02 18:44:11 +08:00