Skip to content

Commit

Permalink
tests: function beautification actually relies no namespace cache
Browse files Browse the repository at this point in the history
  • Loading branch information
darwin committed Nov 9, 2020
1 parent 0a425b3 commit d5c969c
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2 deletions.
3 changes: 2 additions & 1 deletion src/implant/dirac/implant/automation.cljs
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,8 @@
(let [cache-ready-promise (ocall (get-dirac-angel) "getNamespaceCacheReadyPromise")
cache-ready-channel (utils/turn-promise-into-channel cache-ready-promise)]
(go
(<! cache-ready-channel))))
(<! cache-ready-channel)
true)))

; -- main dispatch ----------------------------------------------------------------------------------------------------------

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
(with-scenario "breakpoint"
(testing "enabled :beautify-function-names feature"
(with-devtools
(<!* a/go-wait-for-namespace-cache)
(<!* a/go-trigger! :pause-on-breakpoint)
(<!* a/go-wait-for-devtools-match "setCurrentPanel: sources")
(<!* a/go-scrape! :callstack-pane-functions)
Expand All @@ -19,6 +20,7 @@
(testing "disabled :beautify-function-names feature"
(with-options {:beautify-function-names false}
(with-devtools
(<!* a/go-wait-for-namespace-cache)
(<!* a/go-trigger! :pause-on-breakpoint)
(<!* a/go-wait-for-devtools-match "setCurrentPanel: sources")
(<!* a/go-scrape! :callstack-pane-functions)
Expand All @@ -28,6 +30,7 @@
(with-scenario "exception"
(testing "trigger exception with non-trivial callstack"
(with-devtools
(<!* a/go-wait-for-namespace-cache)
(<!* a/go-switch-to-console-panel!)
(<!* a/go-trigger! :cause-exception)
(<!* a/go-wait-for-match "uncaught exception: Error: :invalid is not ISeqable")
Expand All @@ -36,6 +39,7 @@
(with-scenario "core-async"
(testing "core async stack traces"
(with-devtools
(<!* a/go-wait-for-namespace-cache)
(<!* a/go-trigger! :async)
(<!* a/go-wait-for-devtools-match "setCurrentPanel: sources")
(<!* a/go-wait-for-devtools-ui)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -269,5 +269,5 @@ extension handling command: close-dirac-devtools
extension unregister devtools #4
automate close-scenario! ["scenario-tab#4"]
summary Automated 28 actions with 13 check-points containing 0 assertions.
summary Automated 28 actions with 17 check-points containing 0 assertions.
0 failures, 0 errors.

0 comments on commit d5c969c

Please sign in to comment.