Sha256: 155bd80c75e821ea913cd370b497dbb31ac37c6813ec6150a83304ab31445fec

Contents?: true

Size: 530 Bytes

Versions: 5

Compression:

Stored size: 530 Bytes

Contents

# frozen_string_literal: true

require_relative 'helper'

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

  assert_methods_are_deterministic(
    FFaker::AddressUK,
    :country, :county, :postcode
  )

  def test_county
    assert_match(/[ a-z]/, FFaker::AddressUK.county)
  end

  def test_country
    assert_match(/[ a-z]/, FFaker::AddressUK.country)
  end

  def test_postcode
    assert_match(/^[A-Z]{2}\d \d[A-Z]{2}|[A-Z]{2}\d\d \d[A-Z]{2}$/,
                 FFaker::AddressUK.postcode)
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

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