import moduleForComponent from 'web-client/tests/helpers/module-for-component';
import { test } from 'ember-qunit';
import hbs from 'htmlbars-inline-precompile';
import { getBitsString } from 'web-client/tests/helpers/bits-string';

moduleForComponent('bits/watch-ad-cta', 'Integration | Component | bits/watch ad cta', {
  integration: true
});

test('bits strings and button', function(assert) {
  this.render(hbs`{{bits/watch-ad-cta}}`);

  assert.elementText(this.$('.bits-ads__desc'), getBitsString('ads_for_bits_desc', '', {min:5}), 'Description');
  assert.elementText(this.$('.bits__price button'), getBitsString('button_watch_ad'), 'Button text');
  assert.ok(this.$('.bits__price button').hasClass('button--hollow'), 'Hollow button');
});
