Skip to content

Commit

Permalink
release v0.7.9
Browse files Browse the repository at this point in the history
  • Loading branch information
linfan committed Dec 14, 2022
1 parent 1e9079e commit 0287d27
Show file tree
Hide file tree
Showing 19 changed files with 40 additions and 24 deletions.
2 changes: 1 addition & 1 deletion demo/android-demo/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ dependencies {
testImplementation 'androidx.test:runner:1.4.0-alpha05'
testImplementation 'junit:junit:4.+'
testImplementation 'org.robolectric:robolectric:4.5.1'
testImplementation 'com.alibaba.testable:testable-all:0.7.8'
testImplementation 'com.alibaba.testable:testable-all:0.7.9'
androidTestImplementation 'androidx.test.ext:junit:1.1.1'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0'
}
4 changes: 2 additions & 2 deletions demo/java-demo/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ repositories {

dependencies {
testImplementation('org.junit.jupiter:junit-jupiter:5.6.2')
testImplementation('com.alibaba.testable:testable-all:0.7.8')
testAnnotationProcessor('com.alibaba.testable:testable-processor:0.7.8')
testImplementation('com.alibaba.testable:testable-all:0.7.9')
testAnnotationProcessor('com.alibaba.testable:testable-processor:0.7.9')
}

tasks.withType(JavaCompile) {
Expand Down
2 changes: 1 addition & 1 deletion demo/java-demo/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
<maven.compiler.source>1.8</maven.compiler.source>
<maven.compiler.target>1.8</maven.compiler.target>
<junit.version>5.9.1</junit.version>
<testable.version>0.7.8</testable.version>
<testable.version>0.7.9</testable.version>
</properties>

<dependencies>
Expand Down
4 changes: 2 additions & 2 deletions demo/kotlin-demo/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ dependencies {
implementation("org.jetbrains.kotlin:kotlin-reflect")
implementation("org.jetbrains.kotlin:kotlin-stdlib-jdk8")
testImplementation("org.junit.jupiter:junit-jupiter:5.6.2")
testImplementation("com.alibaba.testable:testable-all:0.7.8")
testAnnotationProcessor("com.alibaba.testable:testable-processor:0.7.8")
testImplementation("com.alibaba.testable:testable-all:0.7.9")
testAnnotationProcessor("com.alibaba.testable:testable-processor:0.7.9")
}

tasks.withType<KotlinCompile> {
Expand Down
2 changes: 1 addition & 1 deletion demo/kotlin-demo/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
<maven.compiler.source>1.8</maven.compiler.source>
<maven.compiler.target>1.8</maven.compiler.target>
<junit.version>5.9.1</junit.version>
<testable.version>0.7.8</testable.version>
<testable.version>0.7.9</testable.version>
</properties>

<dependencies>
Expand Down
4 changes: 2 additions & 2 deletions demo/spock-demo/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ repositories {
dependencies {
testImplementation 'org.codehaus.groovy:groovy-all:3.0.7'
testImplementation 'org.spockframework:spock-core:2.0-M5-groovy-3.0'
testImplementation('com.alibaba.testable:testable-all:0.7.8')
testAnnotationProcessor('com.alibaba.testable:testable-processor:0.7.8')
testImplementation('com.alibaba.testable:testable-all:0.7.9')
testAnnotationProcessor('com.alibaba.testable:testable-processor:0.7.9')
}

tasks.withType(JavaCompile) {
Expand Down
2 changes: 1 addition & 1 deletion demo/spock-demo/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
<java.version>1.8</java.version>
<maven.compiler.source>1.8</maven.compiler.source>
<maven.compiler.target>1.8</maven.compiler.target>
<testable.version>0.7.8</testable.version>
<testable.version>0.7.9</testable.version>
</properties>

<dependencyManagement>
Expand Down
4 changes: 3 additions & 1 deletion docs/en-us/doc/omni-constructor.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,9 @@ Parent parent = OmniConstructor.newInstance(Parent.class);
parent.getChild().getGrandChild().getContent();
```

> **Note**: Based on the light-weight principle, in the default mode, `OmniConstructor` will only uses the original constructor of the class to create objects. For POJO and most model layer objects, this mode has been able to meet the needs.
> Interface and abstract class can also be instantiated by `OmniConstructor`, you can try it e.g. `OmniConstructor.newInstance(CharSequence.class)` ^_^
> **Notice**: Based on the light-weight principle, in the default mode, `OmniConstructor` will only uses the original constructor of the class to create objects. For POJO and most model layer objects, this mode has been able to meet the needs.
> But for more complex situations, such as when certain class have constructors throwing exceptions or contain other statements that hinder the normal execution of the construction, the object construction may fail.
> In those situations, you can use the [Testable global configuration](en-us/doc/javaagent-args.md) `omni.constructor.enhance.enable = true` to enable bytecode enhancement mode of `OmniConstructor`, in this mode, any Java class can be constructed.
Expand Down
6 changes: 6 additions & 0 deletions docs/en-us/doc/release-note.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# Release Note

## 0.7.9
- fix many issues relate to interface instance creation of `OmniConstructor`
- add `@MockContainer` annotation to support multiply parents inheritance between mock classes
- add `targetClassName` parameter to `@MockInvoke` annotation, support mock method of private internal class
- move collection creation methods from `CollectionUtil` class to `CollectionTool` class

## 0.7.8
- support use `OmniConstructor` class to create instance of interface type or abstract class
- provide a `CollectionUtil` class which contains many utility collection creation methods
Expand Down
6 changes: 3 additions & 3 deletions docs/en-us/doc/setup.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ It is recommended to add a `property` field that identifies the TestableMock ver

```xml
<properties>
<testable.version>0.7.8</testable.version>
<testable.version>0.7.9</testable.version>
</properties>
```

Expand Down Expand Up @@ -63,8 +63,8 @@ Add dependence of `TestableMock` in `build.gradle` file:

```groovy
dependencies {
testImplementation('com.alibaba.testable:testable-all:0.7.8')
testAnnotationProcessor('com.alibaba.testable:testable-processor:0.7.8')
testImplementation('com.alibaba.testable:testable-all:0.7.9')
testAnnotationProcessor('com.alibaba.testable:testable-processor:0.7.9')
}
```

Expand Down
2 changes: 2 additions & 0 deletions docs/zh-cn/doc/omni-constructor.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,8 @@ Parent parent = OmniConstructor.newInstance(Parent.class);
parent.getChild().getGrandChild().getContent();
```

> 接口类型和抽象类型也可以直接通过`OmniConstructor`实例化哦,不信试试看`OmniConstructor.newInstance(CharSequence.class)` ^_^
> **注意**:基于轻量优先原则,默认模式下,`OmniConstructor`仅利用类型原有的构造方法来创建对象,对于绝大多数POJO和`Model`层对象而言这种模式已经能够满足需要。
> 但对于更复杂的情形,譬如遇到某些类型的构造方法会抛出异常或包含其他妨碍构造正常执行的语句时,对象构造可能会失败。
> 此时可通过[Testable全局配置](zh-cn/doc/javaagent-args.md)`omni.constructor.enhance.enable = true`启用`OmniConstructor`的字节码增强模式,在该模式下,任何Java类型皆可构造。
Expand Down
6 changes: 6 additions & 0 deletions docs/zh-cn/doc/release-note.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# Release Note

## 0.7.9
- 修复多处`OmniConstructor`创建接口类型对象相关的问题
- 新增`@MockContainer`注解,支持Mock容器类之间的多重继承
- `@MockInvoke`注解新增`targetClassName`参数,支持Mock私有内部类的方法
-`CollectionUtil`中的集合构造方法独立为`CollectionTool`工具类并发布

## 0.7.8
- 支持使用`OmniConstructor`工具类自动创建接口和抽象类的实例
- 提供`CollectionUtil`工具类,包含在测试中常用的集合创建方法
Expand Down
6 changes: 3 additions & 3 deletions docs/zh-cn/doc/setup.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@

```xml
<properties>
<testable.version>0.7.8</testable.version>
<testable.version>0.7.9</testable.version>
</properties>
```

Expand Down Expand Up @@ -63,8 +63,8 @@

```groovy
dependencies {
testImplementation('com.alibaba.testable:testable-all:0.7.8')
testAnnotationProcessor('com.alibaba.testable:testable-processor:0.7.8')
testImplementation('com.alibaba.testable:testable-all:0.7.9')
testAnnotationProcessor('com.alibaba.testable:testable-processor:0.7.9')
}
```

Expand Down
2 changes: 1 addition & 1 deletion testable-agent/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<parent>
<groupId>com.alibaba.testable</groupId>
<artifactId>testable-parent</artifactId>
<version>0.7.8</version>
<version>0.7.9</version>
<relativePath>../testable-parent</relativePath>
</parent>
<artifactId>testable-agent</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion testable-all/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<parent>
<groupId>com.alibaba.testable</groupId>
<artifactId>testable-parent</artifactId>
<version>0.7.8</version>
<version>0.7.9</version>
<relativePath>../testable-parent</relativePath>
</parent>
<artifactId>testable-all</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion testable-core/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<parent>
<groupId>com.alibaba.testable</groupId>
<artifactId>testable-parent</artifactId>
<version>0.7.8</version>
<version>0.7.9</version>
<relativePath>../testable-parent</relativePath>
</parent>
<artifactId>testable-core</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion testable-maven-plugin/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<parent>
<groupId>com.alibaba.testable</groupId>
<artifactId>testable-parent</artifactId>
<version>0.7.8</version>
<version>0.7.9</version>
<relativePath>../testable-parent</relativePath>
</parent>
<artifactId>testable-maven-plugin</artifactId>
Expand Down
4 changes: 2 additions & 2 deletions testable-parent/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>com.alibaba.testable</groupId>
<artifactId>testable-parent</artifactId>
<version>0.7.8</version>
<version>0.7.9</version>
<packaging>pom</packaging>
<name>testable-parent</name>
<description>Unit test enhancement toolkit</description>
Expand Down Expand Up @@ -42,7 +42,7 @@
<plugin.gpg.version>3.0.1</plugin.gpg.version>
<plugin.staging.version>1.6.13</plugin.staging.version>
<plugin.maven.version>3.7.0</plugin.maven.version>
<testable.version>0.7.8</testable.version>
<testable.version>0.7.9</testable.version>
</properties>

<profiles>
Expand Down
2 changes: 1 addition & 1 deletion testable-processor/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<parent>
<groupId>com.alibaba.testable</groupId>
<artifactId>testable-parent</artifactId>
<version>0.7.8</version>
<version>0.7.9</version>
<relativePath>../testable-parent</relativePath>
</parent>
<artifactId>testable-processor</artifactId>
Expand Down

0 comments on commit 0287d27

Please sign in to comment.