GNU bug report logs -
#74786
[PATCH] Add custom args to test compile step
Previous Next
Full log
View this message in rfc822 format
On Friday, December 20th, 2024 at 11:14, O'Brien, Will <will.08rien <at> gmail.com> wrote:
>
>
> Hi,
>
> On Thu, Dec 19 2024 at 16:20, "O'Brien, Will" will.08rien <at> gmail.com wrote:
>
> > I believe the attached patch should cover your suggestion, Randy,
> > as well as incorporating Robert's and J.P.'s suggestions.
Thanks, the patch looks good to me.
There is a typo:
+ "Return the flags for test invoation."
^invocation
>
>
> I think there's a further issue which I believe was pre-existing.
>
> The package test function looks like this:
>
> --8<---------------cut here---------------start------------->8---
>
> (defun go-ts-mode-test-this-package ()
> "Run all the unit tests under the current package."
> (interactive)
> (compile (format "go test -v %s -run %s"
> (go-ts-mode--get-build-tags-flag)
> default-directory)))
> --8<---------------cut here---------------end--------------->8---
>
>
> The issue that the argument to the `-run` flag is a regex that
> should match any tests that will be execute. Passing a directory
> has slightly unexpected consequences, and although it seems to
> work, for me typically results tests not running.
>
> I think that we can remove the `-run` flag from this function.
> What do others think? Also, should this be a separate bug/patch
> (if indeed it is a bug) or I can incorporate this change into the
> current change set.
>
> best
> --
> will
I believe you are correct, we can get rid of the -run flag.
Please incorporate these changes as part of this patch.
(Side note, maybe we should actually pass the package to
go test instead of relying on default directory but
don't worry about that for this patch).
This bug report was last modified 137 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.