Function: go-test-current-test
go-test-current-test is an interactive and natively compiled function
defined in gotest.el.
Signature
(go-test-current-test &optional LAST)
Documentation
Launch go test on the current test.
Key Bindings
This command is not in any keymaps.
Source Code
;; Defined in /nix/store/y8iliarhkh17m4iiwcy1hbi78r7b5489-emacs-packages-deps/share/emacs/site-lisp/elpa/gotest-20230221.945/gotest.el
;;;###autoload
(defun go-test-current-test (&optional last)
"Launch go test on the current test."
(interactive)
(unless (string-equal (symbol-name last) "last")
(setq go-test--current-test-cache (go-test--get-current-test-info)))
(when go-test--current-test-cache
(cl-destructuring-bind (test-suite test-name) go-test--current-test-cache
(let ((test-flag (if (> (length test-suite) 0) "-testify.m " "-run "))
(additional-arguments (if go-test-additional-arguments-function
(funcall go-test-additional-arguments-function
test-suite test-name) "")))
(when test-name
(if (go-test--is-gb-project)
(go-test--gb-start (s-concat "-test.v=true -test.run=" test-name "\\$ ."))
(go-test--go-test (s-concat test-flag test-name "\\$ . " additional-arguments))))))))