Sha256: a42c8b4e2c48c383566cccd29725f201b744afa6f8a0f73eac9f8199fcd3475c

Contents?: true

Size: 543 Bytes

Versions: 1

Compression:

Stored size: 543 Bytes

Contents

require 'minitest/autorun'
require 'minitest/pride'

require_relative '../src/<%= bot_name %>.rb'

class Test<%= class_name %> <  Minitest::Test

  def test_generate_returns_hello_world
    assert_match /Hello/, <%= class_name %>.generate
  end

  def test_generate_returns_less_than_140
    refute [*0...1000].map { |_| <%= class_name %>.generate }.any?{ |t| t.length > 140 }
  end

  def test_hides_greetings
    refute_respond_to <%= class_name %>, :greetings
    assert_instance_of String, <%= class_name %>.send(:greetings)[0]
  end

end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
twitter_bot_generator-0.2.3 lib/twitter_bot_generator/templates/test/test_bot_test.rb.erb