bigbluebutton_rails 0.0.6 → 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- data/.gitignore +1 -1
- data/CHANGELOG.rdoc +8 -0
- data/Gemfile +13 -7
- data/Gemfile.lock +112 -86
- data/README.rdoc +26 -80
- data/Rakefile +2 -1
- data/TODO_08 +13 -0
- data/app/controllers/bigbluebutton/rooms_controller.rb +9 -9
- data/app/controllers/bigbluebutton/servers_controller.rb +1 -1
- data/app/models/bigbluebutton_room.rb +16 -14
- data/app/models/bigbluebutton_server.rb +1 -1
- data/app/views/bigbluebutton/rooms/_form.html.erb +1 -1
- data/app/views/bigbluebutton/rooms/external.html.erb +3 -3
- data/app/views/bigbluebutton/rooms/invite.html.erb +3 -3
- data/app/views/bigbluebutton/servers/_form.html.erb +1 -1
- data/bigbluebutton_rails.gemspec +2 -2
- data/lib/bigbluebutton_rails/version.rb +1 -1
- data/spec/controllers/bigbluebutton/rooms_controller_spec.rb +42 -37
- data/spec/factories/bigbluebutton_room.rb +3 -1
- data/spec/models/bigbluebutton_room_db_spec.rb +34 -0
- data/spec/models/bigbluebutton_room_spec.rb +452 -457
- data/spec/models/bigbluebutton_server_db_spec.rb +14 -0
- data/spec/models/bigbluebutton_server_spec.rb +162 -176
- data/spec/rails_app/.gitignore +2 -1
- data/spec/rails_app/db/seeds.rb +16 -4
- data/spec/rails_app/features/activity_monitor_servers.feature +53 -0
- data/spec/rails_app/features/config.yml.example +13 -0
- data/spec/rails_app/features/create_rooms.feature +17 -0
- data/spec/rails_app/features/create_servers.feature +17 -0
- data/spec/rails_app/features/destroy_rooms.feature +12 -0
- data/spec/rails_app/features/destroy_servers.feature +11 -0
- data/spec/rails_app/features/edit_rooms.feature +26 -0
- data/spec/rails_app/features/edit_servers.feature +24 -0
- data/spec/rails_app/features/join_external_rooms.feature +61 -0
- data/spec/rails_app/features/join_mobile.feature +10 -0
- data/spec/rails_app/features/join_rooms.feature +117 -0
- data/spec/rails_app/features/list_and_show_rooms.feature +18 -0
- data/spec/rails_app/features/list_and_show_servers.feature +16 -0
- data/spec/rails_app/features/step_definitions/activity_monitor_servers_step.rb +102 -0
- data/spec/rails_app/features/step_definitions/common_steps.rb +99 -3
- data/spec/rails_app/features/step_definitions/create_rooms_steps.rb +38 -0
- data/spec/rails_app/features/step_definitions/{bigbluebutton_server_steps.rb → create_servers_steps.rb} +11 -6
- data/spec/rails_app/features/step_definitions/destroy_rooms_steps.rb +17 -0
- data/spec/rails_app/features/step_definitions/destroy_servers_steps.rb +15 -0
- data/spec/rails_app/features/step_definitions/edit_rooms_steps.rb +15 -0
- data/spec/rails_app/features/step_definitions/edit_servers_steps.rb +15 -0
- data/spec/rails_app/features/step_definitions/join_mobile_steps.rb +5 -0
- data/spec/rails_app/features/step_definitions/join_rooms_steps.rb +49 -0
- data/spec/rails_app/features/step_definitions/list_and_show_rooms_steps.rb +11 -0
- data/spec/rails_app/features/step_definitions/list_and_show_servers_steps.rb +11 -0
- data/spec/rails_app/features/support/configurations.rb +34 -0
- data/spec/rails_app/features/support/content.rb +27 -7
- data/spec/rails_app/features/support/env_custom.rb +21 -0
- data/spec/rails_app/features/support/factories/bigbluebutton_server_integration.rb +5 -0
- data/spec/rails_app/features/support/hooks.rb +14 -0
- data/spec/rails_app/features/support/locales.rb +18 -0
- data/spec/rails_app/features/support/paths.rb +25 -10
- data/spec/rails_app/features/support/selectors.rb +26 -0
- data/spec/rails_app/features/support/templates.rb +241 -0
- metadata +43 -20
- data/spec/factories/integration/bigbluebutton_server_integration.rb +0 -8
- data/spec/integration_conf.yml.example +0 -5
- data/spec/rails_app/features/join_external_bigbluebutton_rooms.feature +0 -19
- data/spec/rails_app/features/manage_bigbluebutton_rooms.feature +0 -9
- data/spec/rails_app/features/manage_bigbluebutton_servers.feature +0 -9
- data/spec/rails_app/features/step_definitions/bigbluebutton_room_steps.rb +0 -64
- data/spec/rails_app/features/support/env_gem.rb +0 -10
- data/spec/rails_app/features/support/forms.rb +0 -12
- data/spec/support/integration/integration_conf.rb +0 -16
@@ -1,19 +0,0 @@
|
|
1
|
-
Feature: Join External BigBlueButton Rooms
|
2
|
-
In order to join webconferences that were created from another application
|
3
|
-
One needs to enter his name and a password
|
4
|
-
|
5
|
-
Scenario: Joining an external BigBlueButton room
|
6
|
-
Given a user named "test user"
|
7
|
-
And a server
|
8
|
-
And an external room
|
9
|
-
When the user goes to the join external room page for this room
|
10
|
-
Then he should see a form to join the external room
|
11
|
-
And be able to join the room
|
12
|
-
|
13
|
-
Scenario: Uses the user name as the default to join a room
|
14
|
-
Given a user named "test user"
|
15
|
-
And a server
|
16
|
-
And an external room
|
17
|
-
When the user goes to the join external room page for this room
|
18
|
-
Then he should see a form to join the external room
|
19
|
-
And his name should be in the appropriate input
|
@@ -1,9 +0,0 @@
|
|
1
|
-
Feature: Manage BigBlueButton rooms
|
2
|
-
In order to held webconferences
|
3
|
-
One needs to be able to create and manage BigBlueButton rooms
|
4
|
-
|
5
|
-
Scenario: Register a new BigBlueButton room
|
6
|
-
Given a server
|
7
|
-
When the user goes to the new room page
|
8
|
-
And registers a new room
|
9
|
-
Then he should see the information about this room
|
@@ -1,9 +0,0 @@
|
|
1
|
-
Feature: Manage BigBlueButton servers
|
2
|
-
In order to held webconferences
|
3
|
-
One needs to be able to create and manage BigBlueButton servers
|
4
|
-
|
5
|
-
Scenario: Register a new BigBlueButton server
|
6
|
-
Given a user named "test user"
|
7
|
-
When he goes to the new server page
|
8
|
-
And registers a new server
|
9
|
-
Then he should see the information about this server
|
@@ -1,64 +0,0 @@
|
|
1
|
-
When /a server/i do
|
2
|
-
@server = Factory.create(:bigbluebutton_server_integration)
|
3
|
-
end
|
4
|
-
|
5
|
-
When /^registers a new room$/i do
|
6
|
-
attrs = Factory.attributes_for(:bigbluebutton_room, :server => @server)
|
7
|
-
fill_in("bigbluebutton_room[name]", :with => attrs[:name])
|
8
|
-
fill_in("bigbluebutton_room[meetingid]", :with => attrs[:meetingid])
|
9
|
-
check("bigbluebutton_room[randomize_meetingid]") if attrs[:randomize_meetingid]
|
10
|
-
check("bigbluebutton_room[private]") if attrs[:private]
|
11
|
-
fill_in("bigbluebutton_room[attendee_password]", :with => attrs[:attendee_password])
|
12
|
-
fill_in("bigbluebutton_room[moderator_password]", :with => attrs[:moderator_password])
|
13
|
-
fill_in("bigbluebutton_room[welcome_msg]", :with => attrs[:welcome_msg])
|
14
|
-
fill_in("bigbluebutton_room[logout_url]", :with => attrs[:logout_url])
|
15
|
-
fill_in("bigbluebutton_room[dial_number]", :with => attrs[:dial_number])
|
16
|
-
fill_in("bigbluebutton_room[max_participants]", :with => attrs[:max_participants])
|
17
|
-
check("bigbluebutton_room[external]") if attrs[:external]
|
18
|
-
fill_in("bigbluebutton_room[param]", :with => attrs[:param])
|
19
|
-
# Note: voice_bridge is generated when the BigbluebuttonRoom is created
|
20
|
-
click_button("Create")
|
21
|
-
end
|
22
|
-
|
23
|
-
When /(?:|I ) should see the information about this room/i do
|
24
|
-
room = BigbluebuttonRoom.last
|
25
|
-
page_has_content(room.name)
|
26
|
-
page_has_content(room.meetingid)
|
27
|
-
page_has_content(room.randomize_meetingid)
|
28
|
-
page_has_content(room.private)
|
29
|
-
page_has_content(room.attendee_password)
|
30
|
-
page_has_content(room.moderator_password)
|
31
|
-
page_has_content(room.welcome_msg)
|
32
|
-
page_has_content(room.logout_url)
|
33
|
-
page_has_content(room.dial_number)
|
34
|
-
page_has_content(room.voice_bridge)
|
35
|
-
page_has_content(room.max_participants)
|
36
|
-
page_has_content(room.external)
|
37
|
-
page_has_content(room.param)
|
38
|
-
end
|
39
|
-
|
40
|
-
When /^an external room$/i do
|
41
|
-
@room = Factory.build(:bigbluebutton_room, :server => @server, :external => true)
|
42
|
-
@room.send_create
|
43
|
-
end
|
44
|
-
|
45
|
-
When /(?:|I ) should see a form to join the external room$/i do
|
46
|
-
within(form_selector(external_bigbluebutton_server_rooms_path(@server), 'post')) do
|
47
|
-
has_element("input", { :name => 'meeting', :type => 'hidden', :value => @room.meetingid })
|
48
|
-
has_element("input", { :name => 'user[name]', :type => 'text' })
|
49
|
-
has_element("input", { :name => 'user[password]', :type => 'password' })
|
50
|
-
end
|
51
|
-
end
|
52
|
-
|
53
|
-
When /his name should be in the appropriate input$/i do
|
54
|
-
within(form_selector(external_bigbluebutton_server_rooms_path(@server), 'post')) do
|
55
|
-
has_element("input", { :name => 'user[name]', :type => 'text', :value => @user.name })
|
56
|
-
end
|
57
|
-
end
|
58
|
-
|
59
|
-
When /^be able to join the room$/i do
|
60
|
-
fill_in("user[name]", :with => @user.name)
|
61
|
-
fill_in("user[password]", :with => @room.moderator_password)
|
62
|
-
click_button("Submit")
|
63
|
-
# TODO: check current_url to ensure it is inside the conference
|
64
|
-
end
|
@@ -1,10 +0,0 @@
|
|
1
|
-
# Load the environment to test the gem bigbluebutton_rails using cucumber
|
2
|
-
|
3
|
-
# Load support files
|
4
|
-
Dir["#{File.dirname(__FILE__)}/../../../support/integration/**/*.rb"].each { |f| require f }
|
5
|
-
|
6
|
-
# Load the factories in the gem spec/factories folder
|
7
|
-
require 'factory_girl'
|
8
|
-
require 'forgery'
|
9
|
-
Dir["#{ File.dirname(__FILE__)}/../../../factories/*.rb"].each { |f| require f }
|
10
|
-
Dir["#{ File.dirname(__FILE__)}/../../../factories/integration/*.rb"].each { |f| require f }
|
@@ -1,12 +0,0 @@
|
|
1
|
-
module FormsHelpers
|
2
|
-
|
3
|
-
# Creates a css selector to match a form with certain action, method and possibly other attribues
|
4
|
-
def form_selector(action, method='post', attrs={})
|
5
|
-
attrs[:action] = action
|
6
|
-
attrs[:method] = method
|
7
|
-
make_selector("form", attrs)
|
8
|
-
end
|
9
|
-
|
10
|
-
end
|
11
|
-
|
12
|
-
World(FormsHelpers)
|
@@ -1,16 +0,0 @@
|
|
1
|
-
class IntegrationConf
|
2
|
-
|
3
|
-
cattr_accessor :config
|
4
|
-
|
5
|
-
def self.load
|
6
|
-
@@config = nil
|
7
|
-
file = File.join(File.dirname(__FILE__), "..", "..", "integration_conf.yml")
|
8
|
-
if File.exists? file
|
9
|
-
@@config = YAML.load_file(file)
|
10
|
-
else
|
11
|
-
puts "* Could not load #{file}. Please create it to be able to run the integration tests."
|
12
|
-
exit
|
13
|
-
end
|
14
|
-
end
|
15
|
-
|
16
|
-
end
|