aboutsummaryrefslogtreecommitdiff
path: root/test.rb
diff options
context:
space:
mode:
authorDavid Vazgenovich Shakaryan <dvshakaryan@gmail.com>2014-04-14 14:57:03 -0700
committerDavid Vazgenovich Shakaryan <dvshakaryan@gmail.com>2014-04-14 14:57:03 -0700
commit0fee37a63b588d84b4d91e5ad5074ffb71f698a4 (patch)
tree3ba854e5610ff14d5bdf401313d2e2b6ddccbdb0 /test.rb
parent64cc3ddcea4c6c45298d6e5e65f6b0c74e4d9b0a (diff)
downloaddinobot-0fee37a63b588d84b4d91e5ad5074ffb71f698a4.tar.gz
dinobot-0fee37a63b588d84b4d91e5ad5074ffb71f698a4.tar.xz
Multithreading and timeout functionality.
Diffstat (limited to 'test.rb')
-rw-r--r--test.rb6
1 files changed, 5 insertions, 1 deletions
diff --git a/test.rb b/test.rb
index f2010a0..bc9db29 100644
--- a/test.rb
+++ b/test.rb
@@ -5,7 +5,7 @@ module Dinobot
def initialize
super
- @commands << :echo << :error
+ @commands << :echo << :error << :timeout
end
def echo(user, channel, argument)
@@ -15,5 +15,9 @@ module Dinobot
def error(user, channel, argument)
x
end
+
+ def timeout(user, channel, argument)
+ sleep 60
+ end
end
end