Browse files

Kill processes in the functional test, and make sure that closed

websocket result in killed processes.
  • Loading branch information...
1 parent d29b171 commit 0efcdfe447db605ec188f80ae99caf0a1b48c598 @ahyatt committed Sep 2, 2012
Showing with 10 additions and 0 deletions.
  1. +10 −0 websocket-functional-test.el
View
10 websocket-functional-test.el
@@ -58,6 +58,12 @@
(assert (null (websocket-openp wstest-ws)))
(stop-process wstest-server-proc)
+(kill-process wstest-server-proc)
+
+;; Make sure the processes are closed. This happens asynchronously,
+;; so let's wait for it.
+(sleep-for 1)
+(assert (null (process-list)) t)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; Remote server test, with wss ;;
@@ -116,4 +122,8 @@
(assert (equal (car wstest-msgs) "Hi to self!"))
(websocket-server-close server-conn)
(assert wstest-closed)
+(websocket-close wstest-ws)
+
+(sleep-for 1)
+(assert (null (process-list)) t)
(message "\nAll tests passed!\n")

0 comments on commit 0efcdfe

Please sign in to comment.