Skip to content

Commit cace76d

Browse files
committed
Fix tests and update docs
Fixes #45
1 parent 5d444ef commit cace76d

File tree

5 files changed

+12
-2
lines changed

5 files changed

+12
-2
lines changed

CHANGELOG.md

+4
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,10 @@ All notable changes to this project will be documented in this file.
44
The format follows [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
55
and the project versioning adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html)
66

7+
## [v1.7.1] - 2020-04-28
8+
### Fixed
9+
- [#45](https://github.com/serpro69/kotlin-faker/pull/45) [core] Parameter 'city_name' not found in 'address'
10+
711
## [v1.7.0] - 2020-04-16
812
### Added
913
- [#59](https://github.com/serpro69/kotlin-faker/pull/59) [core] Random money amount

cli-bot/src/main/resources/META-INF/native-image/io.github.serpro69/cli-bot/reflect-config.json

+3-2
Original file line numberDiff line numberDiff line change
@@ -237,8 +237,9 @@
237237
"name":"io.github.serpro69.kfaker.provider.Address",
238238
"methods":[
239239
{"name":"buildingNumber","parameterTypes":[] },
240-
{"name":"city","parameterTypes":[] },
241-
{"name":"cityWithState","parameterTypes":[] },
240+
{"name":"city","parameterTypes":[] },
241+
{"name":"cityName","parameterTypes":[] },
242+
{"name":"cityWithState","parameterTypes":[] },
242243
{"name":"community","parameterTypes":[] },
243244
{"name":"country","parameterTypes":[] },
244245
{"name":"countryByCode","parameterTypes":["java.lang.String"] },

cli-bot/src/test/kotlin/io/github/serpro69/kfaker/app/cli/IntrospectorTest.kt

+1
Original file line numberDiff line numberDiff line change
@@ -380,6 +380,7 @@ class IntrospectorTest : DescribeSpec() {
380380
val expectedFunctions = listOf(
381381
"buildingNumber",
382382
"city",
383+
"cityName",
383384
"cityWithState",
384385
"community",
385386
"country",

core/src/test/kotlin/io/github/serpro69/kfaker/TestConstants.kt

+1
Original file line numberDiff line numberDiff line change
@@ -183,6 +183,7 @@ val addressCategoryKeys = listOf(
183183
"state_abbr",
184184
"time_zone",
185185
"city",
186+
"city_name",
186187
"city_with_state",
187188
"street_name",
188189
"street_address",

doc/address.md

+3
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,9 @@ Faker().address.timeZone() // => Pacific/Midway
3939

4040
Faker().address.city() // => Bartville
4141

42+
// This one is the same as 'city' and is added to fix discrepancies between localized and English dictionaries (see #45)
43+
Faker().address.cityName() // => Bartville
44+
4245
Faker().address.cityWithState() // => Bartville, Indiana
4346

4447
Faker().address.streetName() // => Adams Brook

0 commit comments

Comments
 (0)