big_marker_client 0.1.1 → 0.1.2

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: ce3344c34eea2e6a1155ecc292821e1ba4ddc1aff2c53d8ee80de5bd991ac3b3
4
- data.tar.gz: 81e8dd2e4c2fed2b61f8940401d9bd2fac4e72980d51f442681affcaac1b9503
3
+ metadata.gz: 9158ca174ac5afbc0b1b0057b3e50070f65ec0573a5244b5b5214b9de19d9bbb
4
+ data.tar.gz: 89a8f747bec556b71ecf3ee4ed0d7bf83d9310ea0d9682c6319402527f793c15
5
5
  SHA512:
6
- metadata.gz: ff3ff046e2fef473ed4b2054e79b3a333b6c6e44f9d02d86042321a2a47a70ecf8430513f3644364ec4ab77838a1edceb82901a3884e3a20d8122b1370a7cff3
7
- data.tar.gz: 4274c5d0c42222f05fdfbbd67bdd733417f65b9ea604895a7dcd0028332b9fc56b31943ad5b4f4d53d35c4d56b745e114c3e7a2b59e6a9a98d6a07c4d290c70c
6
+ metadata.gz: cbc3d4cb06b5ee68b65bafa1390ced3f73dc9a00f2c60aa111f7d32f369b4dcabfc24f3fb96b3ecc9a9d0a6521ff37d60ad74dc628ecfc25556c2b272943a484
7
+ data.tar.gz: bc6517c9c88a1f347cc27bf859a76e0b2a6b03078df0967f057e80805092c314d8ab1d0e61a3b3bc1037220b2cdf420d76e3df7d910327cdc7f7ddd23f3a50f0
data/CHANGELOG.md CHANGED
@@ -1,4 +1,8 @@
1
- ## [0.1.1] - Unreleased
1
+ ## [0.1.2] - 2022-01-07
2
+
3
+ - actually package the factories into the gem
4
+
5
+ ## [0.1.1] - 2022-01-07
2
6
 
3
7
  - additional properties `time_zone` and `country` on registrant
4
8
  - factories for external testing
@@ -1,3 +1,3 @@
1
1
  module BigMarkerClient
2
- VERSION = "0.1.1".freeze
2
+ VERSION = "0.1.2".freeze
3
3
  end
@@ -0,0 +1,27 @@
1
+ FactoryBot.define do
2
+ factory :big_marker_attendee, class: "BigMarkerClient::Models::Attendee" do
3
+ sequence(:email) { |n| "attendee#{n}@example.com" }
4
+ first_name { "Attendee first name" }
5
+ last_name { "Attendee last name" }
6
+ entered_at { (Time.now - (60 * BigMarkerClient::TestSupport::MINUTES)).strftime("%FT%T%:z") }
7
+ leaved_at { Time.now.strftime("%FT%T%:z") }
8
+ total_duration { "3600" }
9
+ engaged_duration { "240" }
10
+ chats_count { 1 }
11
+ qas_count { 0 }
12
+ polls_count { 2 }
13
+ polls { %w[poll1 poll2] }
14
+ questions { [] }
15
+ handouts { %w[doc1 doc2 doc3] }
16
+ browser_name { "Google Chrome" }
17
+ browser_version { 96 }
18
+ device_name { "desktop" }
19
+
20
+ initialize_with do
21
+ new(email: email, first_name: first_name, last_name: last_name, entered_at: entered_at, leaved_at: leaved_at,
22
+ total_duration: total_duration, engaged_duration: engaged_duration, chats_count: chats_count,
23
+ qas_count: qas_count, polls_count: polls_count, polls: polls, questions: questions, handouts: handouts,
24
+ browser_name: browser_name, browser_version: browser_version, device_name: device_name)
25
+ end
26
+ end
27
+ end
@@ -0,0 +1,115 @@
1
+ FactoryBot.define do
2
+ factory :big_marker_conference, class: "BigMarkerClient::Models::Conference" do
3
+ transient do
4
+ start_time_obj { Time.now + (3 * BigMarkerClient::TestSupport::DAYS) }
5
+ end
6
+
7
+ id { SecureRandom.hex(6) }
8
+ sequence(:title) { |n| "BigMarker Conference #{n}" }
9
+ event_type { "webinar" }
10
+ display_language { "German(Customized)" }
11
+ meeting_mode { false }
12
+ type { "live_webinar" }
13
+ conference_copy_id { SecureRandom.hex(6) }
14
+ master_webinar_id { nil }
15
+ max_attendance { 500 }
16
+ purpose { "BigMarker event description" }
17
+ start_time { start_time_obj.strftime("%FT%T%:z") }
18
+ duration_minutes { 60 }
19
+ sequence(:conference_address) { |n| "https://host.example.com/example_channel/event-#{n}" }
20
+ custom_event_id { nil }
21
+ channel_id { "example_channel" }
22
+ webcast_mode { "automatic" }
23
+ end_time { (start_time_obj + (duration_minutes * BigMarkerClient::TestSupport::MINUTES)).strftime("%FT%T%:z") }
24
+ moderator_open_time { (start_time_obj - (30 * BigMarkerClient::TestSupport::MINUTES)).strftime("%FT%T%:z") }
25
+ audience_open_time { (start_time_obj - (15 * BigMarkerClient::TestSupport::MINUTES)).strftime("%FT%T%:z") }
26
+ first_admin_enter_time { (start_time_obj - (60 * BigMarkerClient::TestSupport::MINUTES)).strftime("%FT%T%:z") }
27
+ manual_end_time { nil }
28
+ privacy { "public" }
29
+ exit_url { "https://host.example.com" }
30
+ enable_registration_email { true }
31
+ enable_knock_to_enter { false }
32
+ send_reminder_emails_to_presenters { true }
33
+ review_emails { true }
34
+ poll_results { false }
35
+ enable_ie_safari { true }
36
+ enable_twitter { true }
37
+ auto_invite_all_channel_members { false }
38
+ send_cancellation_email { false }
39
+ show_reviews { false }
40
+ registration_required_to_view_recording { true }
41
+ who_can_watch_recording { "everyone" }
42
+ show_handout_on_page { true }
43
+ background_image_url { nil }
44
+ room_logo { nil }
45
+ agenda_topics { [] }
46
+ disclaimer { "disclaimer" }
47
+ recorded { false }
48
+ recording_url { nil }
49
+ recording_iframe { nil }
50
+ sequence(:sub_url) { |n| "event-#{n}" }
51
+ enable_dial_in { true }
52
+ time_zone { "Europe/Berlin" }
53
+ schedule_type { "one_time" }
54
+ recurring_start_times { [] }
55
+ presenter_advanced_enter_time { 60 }
56
+ attendee_advanced_enter_time { 15 }
57
+ webinar_format { "webinar" }
58
+ registration_conf_emails { true }
59
+ send_notification_emails_to_presenters { true }
60
+ webhook_url { nil }
61
+ channel_admin_id { nil }
62
+ free_for_all { false }
63
+ room_type { nil }
64
+ room_sub_title { nil }
65
+ dial_in_information { nil }
66
+ preload_files { [] }
67
+ presenters { [] }
68
+ webinar_stats { nil }
69
+ associated_series { [] }
70
+
71
+ initialize_with do
72
+ new(id: id, title: title, event_type: event_type, display_language: display_language, meeting_mode: meeting_mode,
73
+ type: type, conference_copy_id: conference_copy_id, master_webinar_id: master_webinar_id,
74
+ max_attendance: max_attendance, purpose: purpose, start_time: start_time, duration_minutes: duration_minutes,
75
+ channel_id: channel_id, conference_address: conference_address, custom_event_id: custom_event_id,
76
+ webcast_mode: webcast_mode, end_time: end_time, moderator_open_time: moderator_open_time,
77
+ audience_open_time: audience_open_time, first_admin_enter_time: first_admin_enter_time,
78
+ manual_end_time: manual_end_time, privacy: privacy, exit_url: exit_url,
79
+ enable_registration_email: enable_registration_email, enable_knock_to_enter: enable_knock_to_enter,
80
+ review_emails: review_emails, send_reminder_emails_to_presenters: send_reminder_emails_to_presenters,
81
+ poll_results: poll_results, enable_ie_safari: enable_ie_safari, enable_twitter: enable_twitter,
82
+ auto_invite_all_channel_members: auto_invite_all_channel_members,
83
+ send_cancellation_email: send_cancellation_email, show_reviews: show_reviews,
84
+ registration_required_to_view_recording: registration_required_to_view_recording,
85
+ who_can_watch_recording: who_can_watch_recording, show_handout_on_page: show_handout_on_page,
86
+ background_image_url: background_image_url, room_logo: room_logo, agenda_topics: agenda_topics,
87
+ disclaimer: disclaimer, recorded: recorded, recording_url: recording_url, recording_iframe: recording_iframe,
88
+ sub_url: sub_url, enable_dial_in: enable_dial_in, time_zone: time_zone, schedule_type: schedule_type,
89
+ recurring_start_times: recurring_start_times, presenter_advanced_enter_time: presenter_advanced_enter_time,
90
+ attendee_advanced_enter_time: attendee_advanced_enter_time, webinar_format: webinar_format,
91
+ registration_conf_emails: registration_conf_emails,
92
+ send_notification_emails_to_presenters: send_notification_emails_to_presenters,
93
+ webhook_url: webhook_url, channel_admin_id: channel_admin_id, free_for_all: free_for_all,
94
+ room_type: room_type, room_sub_title: room_sub_title, dial_in_information: dial_in_information,
95
+ preload_files: preload_files, presenters: presenters, webinar_stats: webinar_stats,
96
+ associated_series: associated_series)
97
+ end
98
+
99
+ trait :with_presenters do
100
+ presenters { build_list(:big_marker_presenter, 2, conference_id: id).map(&:to_h) }
101
+ end
102
+
103
+ trait :with_dial_in_information do
104
+ dial_in_information { build(:big_marker_dial_in_information).to_h }
105
+ end
106
+
107
+ trait :with_preload_files do
108
+ preload_files { build_list(:big_marker_preload_file, 2).map(&:to_h) }
109
+ end
110
+
111
+ trait :with_webinar_stats do
112
+ webinar_stats { build(:big_marker_webinar_stats).to_h }
113
+ end
114
+ end
115
+ end
@@ -0,0 +1,16 @@
1
+ FactoryBot.define do
2
+ factory :big_marker_dial_in_information, class: "BigMarkerClient::Models::DialInInformation" do
3
+ dial_in_number { "+1 (312) 248-9348" }
4
+ dial_in_id { "123456#" }
5
+ dial_in_passcode { "1234#" }
6
+ presenter_dial_in_number { "+1 (312) 248-9348" }
7
+ presenter_dial_in_id { "234567#" }
8
+ presenter_dial_in_passcode { "345678#" }
9
+
10
+ initialize_with do
11
+ new(dial_in_number: dial_in_number, dial_in_id: dial_in_id, dial_in_passcode: dial_in_passcode,
12
+ presenter_dial_in_number: presenter_dial_in_number, presenter_dial_in_id: presenter_dial_in_id,
13
+ presenter_dial_in_passcode: presenter_dial_in_passcode)
14
+ end
15
+ end
16
+ end
@@ -0,0 +1,10 @@
1
+ FactoryBot.define do
2
+ factory :big_marker_preload_file, class: "BigMarkerClient::Models::PreloadFile" do
3
+ id { SecureRandom.hex(6) }
4
+ sequence(:file_name) { |n| "presentation_#{n}.pdf" }
5
+ file_type { "whiteboard" }
6
+ file_url { "https://host.example.com/content_object_shared_files/some_hash/#{file_name}{?token" }
7
+
8
+ initialize_with { new(id: id, file_name: file_name, file_type: file_type, file_url: file_url) }
9
+ end
10
+ end
@@ -0,0 +1,40 @@
1
+ FactoryBot.define do
2
+ factory :big_marker_presenter, class: "BigMarkerClient::Models::Presenter" do
3
+ presenter_id { SecureRandom.hex(6) }
4
+ member_id { SecureRandom.hex(6) }
5
+ conference_id { SecureRandom.hex(6) }
6
+ name { "Presenter first name Presenter last name" }
7
+ display_on_landing_page { true }
8
+ presenter_first_name { "Presenter first name" }
9
+ presenter_last_name { "Presenter last name" }
10
+ sequence(:presenter_email) { |n| "presenter.email#{n}@example.com" }
11
+ presenter_url { "https://host.example.com/conferences/#{conference_id}/presenter_content/#{presenter_id}" }
12
+ photo_url { "https://host.example.com/presenters/some_id/medium/presenter_photo.jpg?token" }
13
+ presenter_dial_in_number { "+1 (312) 248-9348" }
14
+ presenter_dial_in_id { "234567#" }
15
+ presenter_dial_in_passcode { "345678#" }
16
+ title { "Presenter title" }
17
+ bio { "Presenter bio" }
18
+ can_manage { false }
19
+ is_moderator { true }
20
+ facebook { nil }
21
+ twitter { nil }
22
+ linkedin { nil }
23
+ website { "https://www.example.com" }
24
+ presenter_temporary_password { "secret" }
25
+ send_email_invite { true }
26
+ add_to_channel_subscriber_list { false }
27
+
28
+ initialize_with do
29
+ new(presenter_id: presenter_id, member_id: member_id, conference_id: conference_id, name: name,
30
+ display_on_landing_page: display_on_landing_page, presenter_first_name: presenter_first_name,
31
+ presenter_last_name: presenter_last_name, presenter_email: presenter_email, presenter_url: presenter_url,
32
+ photo_url: photo_url, presenter_dial_in_number: presenter_dial_in_number,
33
+ presenter_dial_in_id: presenter_dial_in_id, presenter_dial_in_passcode: presenter_dial_in_passcode,
34
+ title: title, bio: bio, can_manage: can_manage, is_moderator: is_moderator, facebook: facebook,
35
+ twitter: twitter, linkedin: linkedin, website: website,
36
+ presenter_temporary_password: presenter_temporary_password, send_email_invite: send_email_invite,
37
+ add_to_channel_subscriber_list: add_to_channel_subscriber_list)
38
+ end
39
+ end
40
+ end
@@ -0,0 +1,22 @@
1
+ FactoryBot.define do
2
+ factory :big_marker_registrant, class: "BigMarkerClient::Models::Registrant" do
3
+ sequence(:email) { |n| "registrant.email#{n}@example.com" }
4
+ first_name { "Registrant first name" }
5
+ last_name { "Registrant last name" }
6
+ custom_fields { [] }
7
+ enter_url { "https://host.example.com/example_channel/event?bmid=#{bmid}" }
8
+ bmid { SecureRandom.hex(6) }
9
+ referral_domain { nil }
10
+ source { "Registration Modal" }
11
+ tracking_code { nil }
12
+ custom_user_id { nil }
13
+ time_zone { "Europe/Berlin" }
14
+ country { "Germany" }
15
+
16
+ initialize_with do
17
+ new(email: email, first_name: first_name, last_name: last_name, custom_fields: custom_fields,
18
+ enter_url: enter_url, bmid: bmid, referral_domain: referral_domain, source: source,
19
+ tracking_code: tracking_code, custom_user_id: custom_user_id, time_zone: time_zone, country: country)
20
+ end
21
+ end
22
+ end
@@ -0,0 +1,14 @@
1
+ FactoryBot.define do
2
+ factory :big_marker_webinar_stats, class: "BigMarkerClient::Models::WebinarStats" do
3
+ registrants { 10 }
4
+ revenue { "$0.00" }
5
+ total_attendees { 5 }
6
+ page_views { 4 }
7
+ invited { 20 }
8
+
9
+ initialize_with do
10
+ new(registrants: registrants, revenue: revenue, total_attendees: total_attendees, page_views: page_views,
11
+ invited: invited)
12
+ end
13
+ end
14
+ end
metadata CHANGED
@@ -1,12 +1,12 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: big_marker_client
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Burkhard Vogel-Kreykenbohm
8
8
  autorequire:
9
- bindir: exe
9
+ bindir: bin
10
10
  cert_chain: []
11
11
  date: 2022-01-07 00:00:00.000000000 Z
12
12
  dependencies:
@@ -70,7 +70,9 @@ description: Encapsulates calls to the BigMarker API to create ond retrieve conf
70
70
  participants, analytics and more
71
71
  email:
72
72
  - bvk@capinside.com
73
- executables: []
73
+ executables:
74
+ - console
75
+ - setup
74
76
  extensions: []
75
77
  extra_rdoc_files: []
76
78
  files:
@@ -100,6 +102,13 @@ files:
100
102
  - lib/big_marker_client/models/webinar_stats.rb
101
103
  - lib/big_marker_client/test_support.rb
102
104
  - lib/big_marker_client/version.rb
105
+ - spec/factories/big_marker/attendee.rb
106
+ - spec/factories/big_marker/conference.rb
107
+ - spec/factories/big_marker/dial_in_infromation.rb
108
+ - spec/factories/big_marker/preload_file.rb
109
+ - spec/factories/big_marker/presenter.rb
110
+ - spec/factories/big_marker/registrant.rb
111
+ - spec/factories/big_marker/webinar_stats.rb
103
112
  homepage: https://gitlab.com/capinside-oss/big_marker_client
104
113
  licenses:
105
114
  - MIT