We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Not repeated in other locales. In Turkish locale, the @JvmField annotation can be used as a workaround.
@JvmField
Kotlin JUnit example:
data class Pizza( //@JvmField val ingredients: String, //@JvmField val sauces: String, ) @Test fun testMustacheInTurkishLocale() { Locale.setDefault(Locale("tr", "TR")) val factory = DefaultMustacheFactory() val ingredients = "cheese, pepperoni" val sauces = "tomato" val template = "pizza: ingredients: {{ingredients}}; sauces: {{sauces}}." val mustache = ByteArrayInputStream(template.toByteArray()).use { input -> factory.compile(input.bufferedReader(), "template_name") } val pizza = Pizza(ingredients, sauces) val actual = ByteArrayOutputStream().use { out -> PrintWriter(out).use { writer -> mustache.execute(writer, pizza) } String(out.toByteArray(), Charsets.UTF_8) } println(actual) val expected = "pizza: ingredients: $ingredients; sauces: $sauces." assertEquals(expected, actual) }
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Not repeated in other locales.
In Turkish locale, the
@JvmField
annotation can be used as a workaround.Kotlin JUnit example:
The text was updated successfully, but these errors were encountered: