lita-team 2.1.0 → 2.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/lita/handlers/update_team.rb +3 -1
- data/lita-team.gemspec +1 -1
- data/spec/lita/handlers/update_team_spec.rb +9 -0
- data/templates/list_team.erb +1 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: fd2cc59c60a1bfbd2bb360c422ae876c8f7fe793
|
4
|
+
data.tar.gz: 3067148dc5343586474d85a68cdf9b6bc30927fa
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b2acaf9f3ab6c907674e0a0d800026ac4b279a0055c316b26a7cef8f3cf8ef10cdef384a6fa59a139edaf6c21d840a8e558424e354ad23c7bf2b0c34ca18c3b8
|
7
|
+
data.tar.gz: 7aa5151c4337ad4c8a77d9a4760ee292482fa0513c16b351fa17317481f99548948bf5f4901c5d074832279c60c088acfc6417c23939dd8c82c6e4e181a883cd
|
@@ -5,12 +5,13 @@ module Lita
|
|
5
5
|
template_root File.expand_path("../../../../templates", __FILE__)
|
6
6
|
|
7
7
|
route(
|
8
|
-
/(\S*) team set (limit|location|icon) (.+)/i,
|
8
|
+
/(\S*) team set (limit|location|time|icon) (.+)/i,
|
9
9
|
:update,
|
10
10
|
command: true,
|
11
11
|
help: {
|
12
12
|
"<name> team set limit <value>" => "update team members limit",
|
13
13
|
"<name> team set location <value>" => "update team location",
|
14
|
+
"<name> team set time <value>" => "update team time",
|
14
15
|
"<name> team set icon <value>" => "update team icon"
|
15
16
|
}
|
16
17
|
)
|
@@ -18,6 +19,7 @@ module Lita
|
|
18
19
|
ATTRIBUTES_MAPPING = {
|
19
20
|
limit: :to_i,
|
20
21
|
location: :to_s,
|
22
|
+
time: :to_s,
|
21
23
|
icon: :to_s
|
22
24
|
}.freeze
|
23
25
|
|
data/lita-team.gemspec
CHANGED
@@ -22,6 +22,15 @@ describe Lita::Handlers::UpdateTeam,
|
|
22
22
|
end
|
23
23
|
end
|
24
24
|
|
25
|
+
context "set time" do
|
26
|
+
it "set time to a given value" do
|
27
|
+
send_command "create testing team"
|
28
|
+
send_command "testing team set time 9:30pm"
|
29
|
+
expect(replies.last).
|
30
|
+
to eq("testing team time set to 9:30pm")
|
31
|
+
end
|
32
|
+
end
|
33
|
+
|
25
34
|
context "set icon" do
|
26
35
|
it "set icon to a given value" do
|
27
36
|
send_command "create testing team"
|
data/templates/list_team.erb
CHANGED
@@ -3,6 +3,7 @@
|
|
3
3
|
|
4
4
|
<%= ":bust_in_silhouette: #{@team[:members].count}" %>
|
5
5
|
<%= " | :round_pushpin: " + @team[:location] if @team[:location] %>
|
6
|
+
<%= " | :clock1: " + @team[:time] if @team[:time] %>
|
6
7
|
<%= " | Max: " + @team[:limit].to_s if @team[:limit] %>
|
7
8
|
|
8
9
|
<% if @team[:members].empty? %>
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: lita-team
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.
|
4
|
+
version: 2.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Edgar Ortega
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-04-01 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: lita
|