Test fixed + pom changes

This commit is contained in:
Sergey Solovyev 2012-04-20 12:41:51 +04:00
parent c033e820fc
commit 1b4a682a61
8 changed files with 102 additions and 97 deletions

View File

@ -1,6 +1,2 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest
xmlns:a="http://schemas.android.com/apk/res/android"
package="org.solovyev.android.calculator"
a:versionCode="1"
a:versionName="1.0"/>
<manifest xmlns:android="http://schemas.android.com/apk/res/android" android:versionCode="1" android:versionName="0.1" package="org.solovyev.android.calculator"/>

View File

@ -32,38 +32,4 @@
</dependencies>
<build>
<extensions>
<extension>
<groupId>com.jayway.maven.plugins.android.generation2</groupId>
<artifactId>android-maven-plugin</artifactId>
<version>3.1.1</version>
</extension>
</extensions>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>properties-maven-plugin</artifactId>
<version>1.0-alpha-2</version>
<executions>
<execution>
<phase>initialize</phase>
<goals>
<goal>read-project-properties</goal>
</goals>
<configuration>
<files>
<file>${basedir}/src/misc/env/env.properties</file>
</files>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>

View File

@ -0,0 +1,3 @@
<resources>
<!--this file is needed only for one purpose - to save res folder as it is needed for build-->
</resources>

View File

@ -133,63 +133,13 @@
<build>
<!-- specifying the resources: e.g. layout.xml, strings.xml etc-->
<resources>
<!-- a pair definition for resource filtering of xml files only (not binary files since they get mangled -->
<resource>
<directory>${project.basedir}/res</directory>
<filtering>true</filtering>
<targetPath>${project.build.directory}/filtered-res</targetPath>
<includes>
<include>**/*.xml</include>
</includes>
</resource>
<resource>
<directory>${project.basedir}/res</directory>
<filtering>false</filtering>
<targetPath>${project.build.directory}/filtered-res</targetPath>
<excludes>
<exclude>**/*.xml</exclude>
</excludes>
</resource>
</resources>
<plugins>
<plugin>
<artifactId>maven-resources-plugin</artifactId>
<version>2.4.3</version>
<executions>
<execution>
<phase>initialize</phase>
<goals>
<goal>resources</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>com.jayway.maven.plugins.android.generation2</groupId>
<artifactId>android-maven-plugin</artifactId>
<extensions>true</extensions>
<configuration>
<resourceDirectory>${project.build.directory}/filtered-res</resourceDirectory>
<manifest>
<debuggable>true</debuggable>
</manifest>
</configuration>
<executions>
<execution>
<id>manifestUpdate</id>
<phase>process-resources</phase>
<goals>
<goal>manifest-update</goal>
</goals>
</execution>
<execution>
<id>alignApk</id>
<phase>package</phase>
@ -198,6 +148,7 @@
</goals>
</execution>
</executions>
</plugin>
<plugin>
@ -213,7 +164,6 @@
<configuration>
<files>
<file>${project.basedir}/src/misc/env/jarsigner.properties</file>
<file>${project.basedir}/src/misc/env/env.properties</file>
</files>
</configuration>
</execution>
@ -334,6 +284,7 @@
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
@ -361,6 +312,7 @@
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>

View File

@ -8,7 +8,7 @@
<string name="c_functions">Функції</string>
<string name="c_fun_decription_sin">Тригонометрична фунція синус.</string>
<string name="c_fun_description_sin">Тригонометрична фунція синус.</string>
<string name="c_fun_description_cos">Тригонометрична функція косинус.</string>
<string name="c_fun_description_tan">Тригонометрична функція тангенс.</string>
<string name="c_fun_description_cot">Тригонометрична функція котангенс.</string>

View File

@ -177,7 +177,7 @@
<string name="c_warning">Увага</string>
<string name="c_error">Помилка</string>
<string name="c_billing_error">Біллінг не підтримується: ви повинні мати обліковий запис Google Checkout, пов'язаний з вашим обліковим записом Google і мати підключення до Інтернету.</string>
<string name="c_billing_error">Біллінг не підтримується: ви повинні мати обліковий запис Google Checkout, повязаний з вашим обліковим записом Google і мати підключення до Інтернету.</string>
<string name="c_calc_ad_free_title">Підтримати проект</string>
<string name="c_calc_ad_free_summary">І позбутися реклами</string>

View File

@ -53,10 +53,10 @@ public class TextHighlighterTest {
Assert.assertEquals("0.1E3", textHighlighter.process("0.1E3").toString());
Assert.assertEquals("1E3", textHighlighter.process("1E3").toString());
Assert.assertEquals("2<b>0x:</b>", textHighlighter.process("20x:").toString());
Assert.assertEquals("20x", textHighlighter.process("20x").toString());
Assert.assertEquals("22x", textHighlighter.process("22x").toString());
Assert.assertEquals("20t", textHighlighter.process("20t").toString());
Assert.assertEquals("20k", textHighlighter.process("20k").toString());
Assert.assertEquals("20g", textHighlighter.process("20g").toString());
Assert.assertEquals("22g", textHighlighter.process("22g").toString());
Assert.assertEquals("20ю", textHighlighter.process("20ю").toString());
Assert.assertEquals("20ъ", textHighlighter.process("20ъ").toString());
Assert.assertEquals("3!!", textHighlighter.process("3!!").toString());
Assert.assertEquals("2", textHighlighter.process("2").toString());
Assert.assertEquals("21", textHighlighter.process("21").toString());

88
pom.xml
View File

@ -16,37 +16,116 @@
<module>calculatorpp-test</module>
</modules>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<android.sdk.path>/home/ssolovyev/projects/org.solovyev/misc/lib/android-sdk-linux_x86</android.sdk.path>
</properties>
<dependencyManagement>
<dependencies>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.8.1</version>
</dependency>
<dependency>
<groupId>com.google.android</groupId>
<artifactId>android</artifactId>
<version>4.0.1.2</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>com.google.android</groupId>
<artifactId>android-test</artifactId>
<version>2.3.1</version>
</dependency>
</dependencies>
</dependencyManagement>
<build>
<!-- specifying the resources: e.g. layout.xml, strings.xml etc-->
<resources>
<!-- a pair definition for resource filtering of xml files only (not binary files since they get mangled -->
<resource>
<directory>${project.basedir}/res</directory>
<filtering>true</filtering>
<targetPath>${project.build.directory}/filtered-res</targetPath>
<includes>
<include>**/*.xml</include>
</includes>
</resource>
<resource>
<directory>${project.basedir}/res</directory>
<filtering>false</filtering>
<targetPath>${project.build.directory}/filtered-res</targetPath>
<excludes>
<exclude>**/*.xml</exclude>
</excludes>
</resource>
</resources>
<plugins>
<plugin>
<artifactId>maven-resources-plugin</artifactId>
<version>2.4.3</version>
<executions>
<execution>
<phase>initialize</phase>
<goals>
<goal>resources</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>com.jayway.maven.plugins.android.generation2</groupId>
<artifactId>android-maven-plugin</artifactId>
<extensions>true</extensions>
<configuration>
<resourceDirectory>${project.build.directory}/filtered-res</resourceDirectory>
<manifest>
<debuggable>true</debuggable>
</manifest>
</configuration>
<executions>
<execution>
<id>manifestUpdate</id>
<phase>process-resources</phase>
<goals>
<goal>manifest-update</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
<pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jarsigner-plugin</artifactId>
<version>1.2</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-resources-plugin</artifactId>
<version>2.4.3</version>
<configuration>
@ -98,6 +177,15 @@
</plugins>
</pluginManagement>
<extensions>
<extension>
<groupId>com.jayway.maven.plugins.android.generation2</groupId>
<artifactId>android-maven-plugin</artifactId>
<version>3.1.1</version>
</extension>
</extensions>
</build>
<profiles>