summaryrefslogtreecommitdiff
path: root/test/lisp/progmodes/flymake-resources
diff options
context:
space:
mode:
authorJoão Távora <joaotavora@gmail.com>2017-09-21 14:57:20 +0100
committerJoão Távora <joaotavora@gmail.com>2017-10-03 13:52:24 +0100
commit0d26e45ab47d781e561bb415e28aab8cb166ced2 (patch)
tree5e080e212454eb35f7a6be226873ae2ba9d08f9f /test/lisp/progmodes/flymake-resources
parent7787988587eacb9aa77bbfb830a885fab8edd828 (diff)
downloademacs-0d26e45ab47d781e561bb415e28aab8cb166ced2.tar.gz
emacs-0d26e45ab47d781e561bb415e28aab8cb166ced2.tar.bz2
emacs-0d26e45ab47d781e561bb415e28aab8cb166ced2.zip
Add a new Flymake test for multiple errors and warnings
* test/lisp/progmodes/flymake-tests.el (flymake-tests--call-with-fixture): Save excursion. (errors-and-warnings): New test. * test/lisp/progmodes/flymake-resources/errors-and-warnings.c: New test fixture.
Diffstat (limited to 'test/lisp/progmodes/flymake-resources')
-rw-r--r--test/lisp/progmodes/flymake-resources/errors-and-warnings.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/test/lisp/progmodes/flymake-resources/errors-and-warnings.c b/test/lisp/progmodes/flymake-resources/errors-and-warnings.c
new file mode 100644
index 00000000000..6454dd20236
--- /dev/null
+++ b/test/lisp/progmodes/flymake-resources/errors-and-warnings.c
@@ -0,0 +1,10 @@
+ int main()
+{
+ char c = 1000;
+ int bla;
+ /* The following line should have one warning and one error. The
+ warning spans the full line because gcc (at least 6.3.0) points
+ places the error at the =, which isn't a sexp.*/
+ char c; if (bla == (void*)3);
+ return c;
+}