Last active
October 3, 2019 20:50
-
-
Save Ruin0x11/acad502240d2f4412932246db03503bc to your computer and use it in GitHub Desktop.
Use VSTest from Emacs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defcustom vstest-assembly "" "VSTest assembly to use") | |
(setq vstest-assembly "C:\\path\\to\\assembly.dll") | |
(defun vstest-console-all () | |
(interactive) | |
(let ((class-name (file-name-sans-extension (buffer-name))) | |
(default-directory (projectile-project-root)) | |
(assembly vstest-assembly)) | |
(compile (concat "vstest.console " assembly)))) | |
(defun vstest-console-this-buffer () | |
(interactive) | |
(let ((class-name (file-name-sans-extension (buffer-name))) | |
(default-directory (projectile-project-root)) | |
(assembly vstest-assembly)) | |
(compile (concat "vstest.console " assembly " /TestCaseFilter:FullyQualifiedName~" class-name)))) | |
(defun vstest-console-this-function () | |
(interactive) | |
(let ((class-name (file-name-sans-extension (buffer-name))) | |
(default-directory (projectile-project-root)) | |
(func-name (which-function)) | |
(assembly vstest-assembly)) | |
(compile (concat "vstest.console " assembly " /TestCaseFilter:\"(FullyQualifiedName~" class-name "&Name=" func-name ")\"")))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment