* test/Makefile.in (SUBDIRS): Suppress "*auto-save-list".
(SUBDIR_TARGETS): New variable.
(subdir_template): Set it.
(subdir-targets): New target.
* test/infra/gitlab-ci.yml (variables): Add CI_DEBUG_TRACE.
(build-image-inotify): Remove timeout.
(generator, test-jobs-pipeline): New jobs.
(test-lisp-inotify, test-lisp-net-inotify): Comment.
* test/infra/test-jobs-generator.sh: New script.
SHELL = @SHELL@
srcdir = @srcdir@
-abs_top_srcdir=@abs_top_srcdir@
+abs_top_srcdir = @abs_top_srcdir@
top_builddir = @top_builddir@
VPATH = $(srcdir)
# directory, we can use emacs --chdir.
EMACS = ../src/emacs
-EMACS_EXTRAOPT=
+EMACS_EXTRAOPT =
# Command line flags for Emacs.
# Apparently MSYS bash would convert "-L :" to "-L ;" anyway,
$(foreach test,${TESTS},$(eval $(call test_template,${test})))
## Get the tests for only a specific directory.
-SUBDIRS = $(sort $(shell cd ${srcdir} && find lib-src lisp misc src -type d ! -path "*resources*" -print))
+SUBDIRS = $(sort $(shell cd ${srcdir} && find lib-src lisp misc src -type d \
+ ! \( -path "*resources*" -o -path "*auto-save-list" \) -print))
+SUBDIR_TARGETS =
define subdir_template
+ SUBDIR_TARGETS += check-$(subst /,-,$(1))
.PHONY: check-$(subst /,-,$(1))
check-$(subst /,-,$(1)):
@${MAKE} check LOGFILES="$(patsubst %.el,%.log, \
check-declare:
$(emacs) -l check-declare \
--eval '(check-declare-directory "$(srcdir)")'
+
+.PHONY: subdir-targets
+
+subdir-targets:
+ @echo $(SUBDIR_TARGETS)
# Three hours, see below.
EMACS_TEST_TIMEOUT: 10800
EMACS_TEST_VERBOSE: 1
- # # Use TLS https://docs.gitlab.com/ee/ci/docker/using_docker_build.html#tls-enabled
+ # Use TLS https://docs.gitlab.com/ee/ci/docker/using_docker_build.html#tls-enabled
# DOCKER_HOST: tcp://docker:2376
# DOCKER_TLS_CERTDIR: "/certs"
# Put the configuration for each run in a separate directory to
# We don't use ${CI_COMMIT_SHA} to be able to do one bootstrap
# across multiple builds.
BUILD_TAG: ${CI_COMMIT_REF_SLUG}
+ # Disable if you don't need it, it can be a security risk.
+ CI_DEBUG_TRACE: "true"
default:
image: docker:19.03.12
extends: [.job-template, .build-template]
variables:
target: emacs-inotify
-# Temporarily.
- timeout: 8 hours
# test-fast-inotify:
# stage: fast
# target: emacs-inotify
# make_params: "-C test check"
-test-lisp-inotify:
- stage: normal
- extends: [.job-template, .test-template]
- variables:
- target: emacs-inotify
- make_params: "-C test check-lisp"
+generator:
+ stage: generate
+ script:
+ - ./test-jobs-generator.sh > test-jobs.yml
+ artifacts:
+ paths:
+ - test-jobs.yml
-test-lisp-net-inotify:
- stage: normal
- extends: [.job-template, .test-template]
- variables:
- target: emacs-inotify
- make_params: "-C test check-lisp-net"
+test-jobs-pipeline:
+ stage: trigger
+ trigger:
+ include:
+ - artifact: test-jobs.yml
+ job: generator
+ strategy: depend
+
+# test-lisp-inotify:
+# stage: normal
+# extends: [.job-template, .test-template]
+# variables:
+# target: emacs-inotify
+# make_params: "-C test check-lisp"
+
+# test-lisp-net-inotify:
+# stage: normal
+# extends: [.job-template, .test-template]
+# variables:
+# target: emacs-inotify
+# make_params: "-C test check-lisp-net"
build-image-filenotify-gio:
stage: platform-images
--- /dev/null
+#!/bin/sh
+
+# Copyright (C) 2021 Free Software Foundation, Inc.
+#
+# This file is part of GNU Emacs.
+#
+# GNU Emacs is free software: you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# GNU Emacs is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with GNU Emacs. If not, see <https://www.gnu.org/licenses/>.
+
+# GNU Emacs support for the GitLab-specific build of Docker images.
+
+# The presence of this file does not imply any FSF/GNU endorsement of
+# Docker or any other particular tool. Also, it is intended for
+# evaluation purposes, thus possibly temporary.
+
+# Maintainer: Michael Albinus <michael.albinus@gmx.de>
+# URL: https://emba.gnu.org/emacs/emacs
+
+for target in $(cd ..; make -s subdir-targets); do
+ case $target in
+ check-lib-src)
+ changes="
+ - lib-src/*.{h,c}
+ - test/lib-src/*.el"
+ ;;
+ check-lisp-emacs-lisp)
+ changes="
+ - lisp/emacs-lisp/*.el
+ - test/lisp/emacs-lisp/*.el"
+ ;;
+ check-lisp-emacs-lisp-eieio-tests)
+ changes="
+ - lisp/emacs-lisp/eieio-tests/*.el
+ - test/lisp/emacs-lisp/eieio-tests/*.el"
+ ;;
+ check-lisp-emacs-lisp-faceup-tests)
+ changes="
+ - lisp/emacs-lisp/faceup-tests/*.el
+ - test/lisp/emacs-lisp/faceup-tests/*.el"
+ ;;
+ check-lisp-mh-e)
+ changes="
+ - lisp/mh-e/*.el
+ - test/lisp/mh-e/*.el"
+ ;;
+ check-lisp-so-long-tests)
+ changes="
+ - lisp/so-long-tests/*.el
+ - test/lisp/so-long-tests/*.el"
+ ;;
+ check-misc)
+ changes="
+ - admin/*.el
+ - test/misc/*.el"
+ ;;
+ check-src)
+ changes="
+ - src/*.{h,c}
+ - test/src/*.el"
+ ;;
+ *)
+ changes="
+ - $(echo -n ${target##check-}/*.el | tr '-' '/')
+ - $(echo -n test${target##check}/*.el | tr '-' '/')"
+ ;;
+ esac
+
+ cat <<EOF
+test${target##check}-inotify:
+ stage: normal
+ extends: [.job-template, .test-template]
+ rules:
+ - changes: $changes
+ variables:
+ target: emacs-inotify
+ make_params: "-C test $target"
+
+EOF
+done