Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unify video show views #1536

Merged
merged 1 commit into from Jan 29, 2016
Merged

Unify video show views #1536

merged 1 commit into from Jan 29, 2016

Conversation

christoomey
Copy link
Contributor

Currently we have 2 show views for videos, show_for_visitors & show_for_subscribers. These views have a great deal of duplication, but have also drifted over time and are slightly different for incidental reasons, rather than consciously.

This change unifies the 2 views making it much easier to understand and think about what a user will see based on the various circumstances under which the view might be rendered (guest vs sampler vs subscriber, trail vs weekly iteration, free sample vs full video vs preview).


context "when the user does not have access to the video" do
it "displays a video preview" do
video = build_stubbed(:video, preview_wistia_id: 'prev')

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Prefer double-quoted strings unless you need single quotes to avoid extra backslashes for escaping.

@raghubetina
Copy link

That is a lot of removed lines! Looks great to me.

Currently we have 2 show views for videos, show_for_visitors &
show_for_subscribers. These views have a great deal of duplication, but have
also drifted over time and are slightly different for incidental reasons, rather
than consciously.

This change unifies the 2 views making it much easier to understand and think
about what a user will see based on the various circumstances under which the
view might be rendered (guest vs sampler vs subscriber, trail vs weekly
iteration, free sample vs full video vs preview).
@christoomey christoomey merged commit c42b6b8 into master Jan 29, 2016
@christoomey christoomey deleted the cjt-unify-video-views branch January 29, 2016 20:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants