Sha256: 33fd4113bdb91a6324aa87f17559bcea959364a26c9c6f743e7d66276904f836

Contents?: true

Size: 501 Bytes

Versions: 5

Compression:

Stored size: 501 Bytes

Contents

# frozen_string_literal: true

require_relative 'helper'

class TestFakerNameDE < Test::Unit::TestCase
  include DeterministicHelper

  assert_methods_are_deterministic(FFaker::NameDE, :name, :prefix, :suffix)

  def setup
    @tester = FFaker::NameDE
  end

  def test_name
    assert_match(/\A([\w']+\.? ?){2,3}\z/, @tester.name)
  end

  def test_prefix
    assert_match(/\A[A-Z][a-z]+\.?\z/, @tester.prefix)
  end

  def test_suffix
    assert_include(@tester::SUFFIXES, @tester.suffix)
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
ffaker-2.23.0 test/test_name_de.rb
ffaker-2.22.0 test/test_name_de.rb
ffaker-2.21.0 test/test_name_de.rb
ffaker-2.20.0 test/test_name_de.rb
ffaker-2.19.0 test/test_name_de.rb