Sha256: 77c3efcf418b2535cf0f69bdeb732264217e1f8a4f1272ff1829eb8c158fb2e9

Contents?: true

Size: 500 Bytes

Versions: 20

Compression:

Stored size: 500 Bytes

Contents

require_relative '../../../../lib/sendgrid/helpers/mail/mail'
require 'minitest/autorun'

class TestCategory < Minitest::Test

  include SendGrid

  def setup
    @category = Category.new(name: 'foo')
  end

  def test_aliases
    assert_equal @category.method(:name), @category.method(:category)
  end

  def test_name
    assert_equal @category.name, 'foo'
  end

  def test_to_json
    expected_json = {
      'category' => 'foo'
    }
    assert_equal @category.to_json, expected_json
  end

end

Version data entries

20 entries across 20 versions & 1 rubygems

Version Path
sendgrid-ruby-6.3.4 test/sendgrid/helpers/mail/test_category.rb
sendgrid-ruby-6.3.3 test/sendgrid/helpers/mail/test_category.rb
sendgrid-ruby-6.3.2 test/sendgrid/helpers/mail/test_category.rb
sendgrid-ruby-6.3.1 test/sendgrid/helpers/mail/test_category.rb
sendgrid-ruby-6.2.1 test/sendgrid/helpers/mail/test_category.rb
sendgrid-ruby-6.2.0 test/sendgrid/helpers/mail/test_category.rb
sendgrid-ruby-6.1.4 test/sendgrid/helpers/mail/test_category.rb
sendgrid-ruby-6.1.3 test/sendgrid/helpers/mail/test_category.rb
sendgrid-ruby-6.1.2 test/sendgrid/helpers/mail/test_category.rb
sendgrid-ruby-6.1.1 test/sendgrid/helpers/mail/test_category.rb
sendgrid-ruby-6.1.0 test/sendgrid/helpers/mail/test_category.rb
sendgrid-ruby-6.0.4 test/sendgrid/helpers/mail/test_category.rb
sendgrid-ruby-6.0.3 test/sendgrid/helpers/mail/test_category.rb
sendgrid-ruby-6.0.2 test/sendgrid/helpers/mail/test_category.rb
sendgrid-ruby-6.0.1 test/sendgrid/helpers/mail/test_category.rb
sendgrid-ruby-6.0.0 test/sendgrid/helpers/mail/test_category.rb
sendgrid-ruby-5.3.0 test/sendgrid/helpers/mail/test_category.rb
sendgrid-ruby-5.2.0 test/sendgrid/helpers/mail/test_category.rb
sendgrid-ruby-5.1.0 test/sendgrid/helpers/mail/test_category.rb
sendgrid-ruby-5.0.0 test/sendgrid/helpers/mail/test_category.rb