commit | 8ef8bfe936d01899e43a55cfb830bfb8a1d06272 | [log] [tgz] |
---|---|---|
author | Taylor Santiago <taylorsantiago@google.com> | Fri Dec 09 15:40:29 2022 -0800 |
committer | Taylor Santiago <taylorsantiago@google.com> | Fri Dec 09 16:00:01 2022 -0800 |
tree | 160331626913c4380cda5b3e7f9e3d07017500c1 | |
parent | 941930a81a5399016067111def07cbad5bfc03a8 [diff] |
Fix addTapListener both on initial load and on navigation. Initial page load attempted to access a stale actionsApi that was set at construction time. This wasn't valid until a SHOW_REVISION_ACTIONS occurred. Snapshots of actionsApi and restApi were used across page navigation. These stale references would prevent proper addTapListener registration. Change-Id: I12ffd0433badccb5370505f3ac391b8d458d9480
See src/main/resources/documentation.
For running unit tests execute:
bazel test --test_output=all //plugins/automerger/web:karma_test
For checking or fixing eslint formatter problems run:
bazel test //plugins/automerger/web:lint_test bazel run //plugins/automerger/web:lint_bin -- --fix "$(pwd)/plugins/automerger/web"
For testing the plugin with Gerrit FE Dev Helper build the JavaScript bundle and copy it to the plugins/
folder:
bazel build //plugins/automerger/web:automerger cp -f bazel-bin/plugins/automerger/web/automerger.js plugins/
and let the Dev Helper redirect from .+/plugins/automerger/static/automerger.js
to http://localhost:8081/plugins_/automerger.js
.