Skip to content

Commit

Permalink
chore(bydi): upgrade to v0.8.0 and adapt tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Walheimat committed Aug 30, 2024
1 parent 5d1a7b4 commit c3cc089
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 15 deletions.
2 changes: 1 addition & 1 deletion Cask
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
(source melpa)

(development
(depends-on "bydi" :git "https://github.com/Walheimat/bydi" :ref "v0.7.0")
(depends-on "bydi" :git "https://github.com/Walheimat/bydi" :ref "v0.8.0")
(depends-on "ert-runner")
(depends-on "shut-up")
(depends-on "undercover")
Expand Down
6 changes: 3 additions & 3 deletions test/ship-mate-edit-test.el
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@

(call-interactively 'ship-mate-edit-environment)

(bydi-was-called ship-mate-edit-environment--internal t)
(bydi-was-called ship-mate-edit-environment--internal :clear t)

(setq buffer nil)

Expand Down Expand Up @@ -185,7 +185,7 @@

(ship-mate-edit-history-abort)

(bydi-was-called ship-mate-edit-history--quit t)
(bydi-was-called ship-mate-edit-history--quit :clear t)
(bydi-was-not-called ship-mate-edit-history--set-history)

(ship-mate-edit-history-apply)
Expand Down Expand Up @@ -241,7 +241,7 @@

(call-interactively 'ship-mate-edit-history)

(bydi-was-called ship-mate-edit-history--internal t))))
(bydi-was-called ship-mate-edit-history--internal :clear t))))

(ert-deftest ship-mate-edit-setup-bindings ()
:tags '(user-facing edit)
Expand Down
12 changes: 6 additions & 6 deletions test/ship-mate-submarine-test.el
Original file line number Diff line number Diff line change
Expand Up @@ -132,14 +132,14 @@

;; Process is dead, will surface.
(ship-mate-submarine--check)
(bydi-was-called ship-mate-submarine--surface t)
(bydi-was-called ship-mate-submarine--surface :clear t)

;; Runs with idle timer if set.
(setq ship-mate-submarine-prompt-for-hidden-buffer t)
(ship-mate-submarine--check)
(bydi-was-called ship-mate-submarine--clear-process t)
(bydi-was-called ship-mate-submarine--clear-process :clear t)
(bydi-was-not-called ship-mate-submarine--surface)
(bydi-was-called run-with-idle-timer t)
(bydi-was-called run-with-idle-timer :clear t)

;; Clears process if not a hidden buffer.
(bydi-toggle-volatile 'ship-mate-submarine--hidden-buffer-p)
Expand Down Expand Up @@ -248,7 +248,7 @@

(bydi-was-called ship-mate-submarine--clear-process)
(bydi-was-set-to ship-mate--hidden nil)
(bydi-was-called pop-to-buffer t)
(bydi-was-called pop-to-buffer :clear t)

;; Doesn't surface already visible buffer.
(bydi-toggle-sometimes)
Expand Down Expand Up @@ -333,14 +333,14 @@

(call-interactively 'ship-mate-submarine-show-hidden)

(bydi-was-called ship-mate-submarine--surface 'process)
(bydi-was-called ship-mate-submarine--surface)
(bydi-was-not-called ship-mate--complete-buffer)

(setq ship-mate-submarine--processes '(a b))

(call-interactively 'ship-mate-submarine-show-hidden)

(bydi-was-called ship-mate-submarine--surface nil)
(bydi-was-called ship-mate-submarine--surface)
(bydi-was-called ship-mate--complete-buffer))))

(ert-deftest ship-mate-hide-visible ()
Expand Down
10 changes: 5 additions & 5 deletions test/ship-mate-test.el
Original file line number Diff line number Diff line change
Expand Up @@ -203,9 +203,9 @@

(ship-mate-command--compile 'test "make test")

(bydi-was-called ship-mate-environment--current-environment t)
(bydi-was-called ship-mate-environment--current-environment :clear t)
(bydi-was-not-called ship-mate-environment--edit-in-minibuffer)
(bydi-was-set-to compilation-environment '("TES=TING") t)
(bydi-was-set-to compilation-environment '("TES=TING") :clear t)

(setq compilation-environment env)
(ship-mate-command--compile 'test "make test" nil '(5))
Expand All @@ -232,7 +232,7 @@

(should (ship-mate-command--current-project))

(bydi-was-called project-current t)
(bydi-was-called project-current :clear t)

(let ((ship-mate-other-project-prefix 2))
(should (ship-mate-command--current-project '(2))))
Expand Down Expand Up @@ -754,7 +754,7 @@

(bydi-was-called-with modify-dir-local-variable
'(nil ship-mate-test-default-cmd ("make coverage" "make test") add-or-replace)
t)
:clear t)

(ship-mate-command--store-history-as-default 'test t)

Expand Down Expand Up @@ -863,7 +863,7 @@
(ert-simulate-keys '(?\C-m)
(ship-mate--complete-buffer "Some prompt: "))

(bydi-was-set-to ship-mate--complete-for-all nil t)
(bydi-was-set-to ship-mate--complete-for-all nil :clear t)
(bydi-was-set minibuffer-completion-table)

(ert-simulate-keys '(?\C-m)
Expand Down

0 comments on commit c3cc089

Please sign in to comment.