The application is not internationalized, so I don't use property files
in the test code or tested code.
The $LANG variable is de_DE.utf8 on both machines.
Sorry, I didn't catch your last point.
Am 18.10.2010 23:30, per-henrik hedman wrote:
Are you using property files in resources? Those could be stored differently.
What are your default encoding on your machines? It could be that some
of the behavior, eg the different configurations that you are using
aren't used and then it falls back to default behavior.
Another thing can be that your are encoding an extra time, and that
could make that kind of weird behavior...
Good luck,
Per
On Mon, Oct 18, 2010 at 11:11 PM, Andreas Simon<[email protected]> wrote:
I verified the source code and the test code file with Linux' file command.
Both are identified as "UTF-8 Unicode Java program text". I checked on the
failing SuSE system.
Am 18.10.2010 22:54, Anders Hammar wrote:
Have you verified that all Java files involved are in fact using UTF-8
char
encoding (check on the machine where it fails!)? Check both source code
and
test code files.
I don't think it's obvious that the are compiled with different encodings.
The problem could maybe be that they are retrieved from your scm (or
stored
in the scm) with the wrong encoding.
/Anders
On Mon, Oct 18, 2010 at 22:30, Andreas Simon<[email protected]> wrote:
Thank you for your reply!
On my developer machine is Ubuntu 10.04. Same result when running Oracle
JDK 1.6.0u21.
What are you running on your developer machine? Can you run it with
Oracle
JDK?
Cheers,
Per Hedman
On Mon, Oct 18, 2010 at 8:51 PM, Andreas Simon<[email protected]>
wrote:
Hi all,
I got a quite strange problem with my tests. I have 3 tests that shall
control some messages for the user. These messages contain some German
umlauts (ä, ö, ü and ß). On my Ubuntu developer machine the tests run
fine.
On my SuSE integration server the tests fail. The assertions fail with
the
following message:
expected:<...ü...> but was:<...??...>
Obviously, the test files and the tested file are compiled with
different
encodings.
I have tried several settings with UTF-8,
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.3.2</version>
<executions>
<execution>
<id>src-compile</id>
<phase>compile</phase>
<goals>
<goal>compile</goal>
</goals>
<configuration>
<source>1.5</source>
<target>1.5</target>
<encoding>UTF-8</encoding>
<fork>true</fork>
<inputEncoding>UTF-8</inputEncoding>
<outputEncoding>UTF-8</outputEncoding>
<argLine>-Dfile.encoding=utf8</argLine>
</configuration>
</execution>
<execution>
<id>default-compile</id>
<phase>test-compile</phase>
<goals>
<goal>testCompile</goal>
</goals>
<configuration>
<source>1.5</source>
<target>1.5</target>
<encoding>UTF-8</encoding>
<fork>true</fork>
<inputEncoding>UTF-8</inputEncoding>
<outputEncoding>UTF-8</outputEncoding>
<argLine>-Dfile.encoding=utf8</argLine>
</configuration>
</execution>
</executions>
<configuration>
<source>1.5</source>
<target>1.5</target>
<encoding>UTF-8</encoding>
<fork>true</fork>
<inputEncoding>UTF-8</inputEncoding>
<outputEncoding>UTF-8</outputEncoding>
<argLine>-Dfile.encoding=utf8</argLine>
</configuration>
</plugin>
</plugins>
</build>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<maven.compile.encoding>UTF-8</maven.compile.encoding>
</properties>
Some settings are redundant, but two are better than one. Any way,
these
settings don't apply to the compiling of the test files. I have
searched
some hours for similar problems, but I found no other solution. To be
complete, my configuration:
SuSE 11.1
IBM JDK 1.5.0
Maven 2.2.1
Thanks for any idea,
Andreas
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]