* [PATCH 3/3] new test case for I/O switching
@ 2012-08-15 14:49 Tom Tromey
2012-08-15 16:07 ` Stefan Monnier
0 siblings, 1 reply; 5+ messages in thread
From: Tom Tromey @ 2012-08-15 14:49 UTC (permalink / raw)
To: Emacs discussions
This adds a new test case that demonstrates that Emacs task-switches
while waiting for I/O.
---
test/automated/threads.el | 13 +++++++++++++
1 files changed, 13 insertions(+), 0 deletions(-)
diff --git a/test/automated/threads.el b/test/automated/threads.el
index b09e269..4c1afbd 100644
--- a/test/automated/threads.el
+++ b/test/automated/threads.el
@@ -162,4 +162,17 @@
(thread-join thr))
t)))
+(defun threads-test-io-switch ()
+ (setq threads-test-global 23))
+
+(ert-deftest threads-io-switch ()
+ "test that accept-process-output causes thread switch"
+ (should
+ (progn
+ (setq threads-test-global nil)
+ (make-thread #'threads-test-io-switch)
+ (while (not threads-test-global)
+ (accept-process-output nil 1))
+ threads-test-global)))
+
;;; threads.el ends here
--
1.7.7.6
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH 3/3] new test case for I/O switching
2012-08-15 14:49 [PATCH 3/3] new test case for I/O switching Tom Tromey
@ 2012-08-15 16:07 ` Stefan Monnier
2012-08-15 19:40 ` Tom Tromey
0 siblings, 1 reply; 5+ messages in thread
From: Stefan Monnier @ 2012-08-15 16:07 UTC (permalink / raw)
To: Tom Tromey; +Cc: Emacs discussions
Can you make a new `concurrency' branch in the Bzr repository?
Stefan
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH 3/3] new test case for I/O switching
2012-08-15 16:07 ` Stefan Monnier
@ 2012-08-15 19:40 ` Tom Tromey
2012-08-16 2:05 ` Stefan Monnier
0 siblings, 1 reply; 5+ messages in thread
From: Tom Tromey @ 2012-08-15 19:40 UTC (permalink / raw)
To: Stefan Monnier; +Cc: Emacs discussions
Stefan> Can you make a new `concurrency' branch in the Bzr repository?
If you mean one literally named "concurrency", then I don't know how to
do that. Perhaps somebody more conversant with bzr can rename the old
branch first.
I can make one like "concurrency-2" easily enough.
Tom
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH 3/3] new test case for I/O switching
2012-08-15 19:40 ` Tom Tromey
@ 2012-08-16 2:05 ` Stefan Monnier
2012-08-16 15:01 ` Tom Tromey
0 siblings, 1 reply; 5+ messages in thread
From: Stefan Monnier @ 2012-08-16 2:05 UTC (permalink / raw)
To: Tom Tromey; +Cc: Emacs discussions
Stefan> Can you make a new `concurrency' branch in the Bzr repository?
> If you mean one literally named "concurrency", then I don't know how to
> do that. Perhaps somebody more conversant with bzr can rename the old
> branch first.
I renamed "concurrency" to "old-concurrency", so you can name it
"concurrency".
Stefan
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH 3/3] new test case for I/O switching
2012-08-16 2:05 ` Stefan Monnier
@ 2012-08-16 15:01 ` Tom Tromey
0 siblings, 0 replies; 5+ messages in thread
From: Tom Tromey @ 2012-08-16 15:01 UTC (permalink / raw)
To: Stefan Monnier; +Cc: Emacs discussions
Stefan> I renamed "concurrency" to "old-concurrency", so you can name it
Stefan> "concurrency".
Thanks. I pushed the branch.
Tom
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2012-08-16 15:01 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-08-15 14:49 [PATCH 3/3] new test case for I/O switching Tom Tromey
2012-08-15 16:07 ` Stefan Monnier
2012-08-15 19:40 ` Tom Tromey
2012-08-16 2:05 ` Stefan Monnier
2012-08-16 15:01 ` Tom Tromey
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.