summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMaciej Barć <xgqt@gentoo.org>2022-05-24 13:55:27 +0200
committerMaciej Barć <xgqt@gentoo.org>2022-05-24 14:35:03 +0200
commitd46fdb7e7ebdae95982c771839a09882717fa6d3 (patch)
treecea13bb570d52db0b56b2097fd381d467979d611 /app-emacs/with-simulated-input
parent*/*: Rename sourceforge-jp remote-id to osdn (diff)
downloadgentoo-d46fdb7e7ebdae95982c771839a09882717fa6d3.tar.gz
gentoo-d46fdb7e7ebdae95982c771839a09882717fa6d3.tar.bz2
gentoo-d46fdb7e7ebdae95982c771839a09882717fa6d3.zip
app-emacs/with-simulated-input: new package; add version 3.0
Signed-off-by: Maciej Barć <xgqt@gentoo.org>
Diffstat (limited to 'app-emacs/with-simulated-input')
-rw-r--r--app-emacs/with-simulated-input/Manifest1
-rw-r--r--app-emacs/with-simulated-input/files/50with-simulated-input-gentoo.el1
-rw-r--r--app-emacs/with-simulated-input/metadata.xml21
-rw-r--r--app-emacs/with-simulated-input/with-simulated-input-3.0.ebuild29
4 files changed, 52 insertions, 0 deletions
diff --git a/app-emacs/with-simulated-input/Manifest b/app-emacs/with-simulated-input/Manifest
new file mode 100644
index 000000000000..7b7d7dde3c4f
--- /dev/null
+++ b/app-emacs/with-simulated-input/Manifest
@@ -0,0 +1 @@
+DIST with-simulated-input-3.0.tar.gz 26203 BLAKE2B 2629f28449a71828f67209b84123ee11b9eb838884560836129830f1c6e0dc12e95ba56e806de5eae8b29cbe1b3f199f9a9e292a2f048483b61a64aa138d2848 SHA512 ddb916e51e8f1da76a19a440f0a629ece6e27969be38b70d8b5156ab7c41084ef9a099970e2c74a680e0cdf75463698e60336fcd168f82d62acd1e0994d6897a
diff --git a/app-emacs/with-simulated-input/files/50with-simulated-input-gentoo.el b/app-emacs/with-simulated-input/files/50with-simulated-input-gentoo.el
new file mode 100644
index 000000000000..431f7e90ae73
--- /dev/null
+++ b/app-emacs/with-simulated-input/files/50with-simulated-input-gentoo.el
@@ -0,0 +1 @@
+(add-to-list 'load-path "@SITELISP@")
diff --git a/app-emacs/with-simulated-input/metadata.xml b/app-emacs/with-simulated-input/metadata.xml
new file mode 100644
index 000000000000..64bd70a80275
--- /dev/null
+++ b/app-emacs/with-simulated-input/metadata.xml
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
+
+<pkgmetadata>
+ <maintainer type="project">
+ <email>gnu-emacs@gentoo.org</email>
+ <name>Gentoo GNU Emacs project</name>
+ </maintainer>
+ <upstream>
+ <bugs-to>https://github.com/DarwinAwardWinner/with-simulated-input/issues/</bugs-to>
+ <remote-id type="github">DarwinAwardWinner/with-simulated-input</remote-id>
+ </upstream>
+ <longdescription>
+ This package provides an Emacs Lisp macro, with-simulated-input, which
+ evaluates one or more forms while simulating a sequence of input events for
+ those forms to read. The result is the same as if you had evaluated the
+ forms and then manually typed in the same input. This macro is useful for
+ non-interactive testing of normally interactive commands and functions,
+ such as completing-read.
+ </longdescription>
+</pkgmetadata>
diff --git a/app-emacs/with-simulated-input/with-simulated-input-3.0.ebuild b/app-emacs/with-simulated-input/with-simulated-input-3.0.ebuild
new file mode 100644
index 000000000000..33361e6ac49a
--- /dev/null
+++ b/app-emacs/with-simulated-input/with-simulated-input-3.0.ebuild
@@ -0,0 +1,29 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+NEED_EMACS=24.4
+
+inherit elisp
+
+DESCRIPTION="Emacs Lisp macro to simulate user input non-interactively"
+HOMEPAGE="https://github.com/DarwinAwardWinner/with-simulated-input/"
+SRC_URI="https://github.com/DarwinAwardWinner/${PN}/archive/v${PV}.tar.gz
+ -> ${P}.tar.gz"
+
+LICENSE="GPL-3+"
+KEYWORDS="~amd64 ~x86"
+SLOT="0"
+IUSE="test"
+RESTRICT="!test? ( test )"
+
+BDEPEND="test? ( app-emacs/buttercup )"
+
+DOCS=( README.md )
+ELISP_REMOVE="tests/test-${PN}.el" # Remove failing tests; 11/49 specs
+SITEFILE="50${PN}-gentoo.el"
+
+src_test() {
+ buttercup -L . -L tests --traceback full tests || die
+}