Skip to content

Commit

Permalink
Merge pull request eclipse-archived#480 from dnobel/fixed-i18n-tests
Browse files Browse the repository at this point in the history
Fixed failing i18n tests.
  • Loading branch information
kaikreuzer committed Oct 2, 2015
2 parents 7db6f4e + 72e4f8b commit db421ac
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -75,13 +75,13 @@ class ThingTypeI18nTest extends OSGiTest {

def weatherGroupType = thingTypes.find { it.toString().equals("yahooweather:weather-with-group") } as ThingType
println weatherGroupType.channelGroupDefinitions[0].typeUID
println TypeResolver.resolve(weatherGroupType.channelGroupDefinitions[0].typeUID).label
println TypeResolver.resolve(weatherGroupType.channelGroupDefinitions[0].typeUID, Locale.GERMAN).label

assertThat weatherGroupType, is(notNullValue())
assertEquals("""
label = Wetterinformation mit Gruppe
description = Wetterinformation mit Gruppe Beschreibung
""", asString(TypeResolver.resolve(weatherGroupType.channelGroupDefinitions[0].typeUID)))
""", asString(TypeResolver.resolve(weatherGroupType.channelGroupDefinitions[0].typeUID, Locale.GERMAN)))
}

@Test
Expand All @@ -98,7 +98,7 @@ class ThingTypeI18nTest extends OSGiTest {
assertThat thingTypes.size(), is(initialNumberOfThingTypes + 2)

def weatherType = thingTypes.find { it.toString().equals("yahooweather:weather") } as ThingType
def temperatureChannelType = TypeResolver.resolve(weatherType.channelDefinitions.find { it.getId().equals("temperature")}.channelTypeUID) as ChannelType
def temperatureChannelType = TypeResolver.resolve(weatherType.channelDefinitions.find { it.getId().equals("temperature")}.channelTypeUID, Locale.GERMAN) as ChannelType

assertEquals("""
label = Temperatur
Expand Down

0 comments on commit db421ac

Please sign in to comment.