Skip to content

Commit 3f14c92

Browse files
committed
build 4.0
1 parent fe2e12c commit 3f14c92

File tree

5 files changed

+42
-7
lines changed

5 files changed

+42
-7
lines changed

CHANGELOG.md

Lines changed: 19 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,27 @@
11
# Changelog
22

33
## Versions
4-
* 3.x: PhpStorm 2017.3+
5-
* 2.x: PhpStorm 2017.1+
4+
* 4.x: PhpStorm 2020.1+
5+
* 3.x: PhpStorm 2017.3+ (no support)
6+
* 2.x: PhpStorm 2017.1+ (no support)
67
* 1.x: PhpStorm 2016.1+ (no support)
78

9+
## 4.0
10+
* Allow all PhpUnit mock instance in chaining for finding createMock [#39](https://github.com/Haehnchen/idea-php-phpunit-plugin/issues/39) (Daniel Espendiller)
11+
* Provide support for "PHPUnit\\Framework\\MockObject\\Stub::method" [#42](https://github.com/Haehnchen/idea-php-phpunit-plugin/issues/42) [#39](https://github.com/Haehnchen/idea-php-phpunit-plugin/issues/39) (Daniel Espendiller)
12+
* Dropping feature support for build < 2020.1; api is still valid so by now no build-since highering needed (Daniel Espendiller)
13+
* Support also Behat tests file structure (Daniel Espendiller)
14+
* Fix isPrimitiveType checking for constructor creation intention (Daniel Espendiller)
15+
* Remove deprecated code (Daniel Espendiller)
16+
* Remove runner linemarker in favor of already provide by PhpStorm (Daniel Espendiller)
17+
* Add plugin icon (Daniel Espendiller)
18+
* Allow "setUpBeforeTest" to be a valid "setUp" method for checking property types #35 (Daniel Espendiller)
19+
* Allow some more use cases for checking test context eg for Behat [#37](https://github.com/Haehnchen/idea-php-phpunit-plugin/issues/37) (Daniel Espendiller)
20+
* Add support for phpspec/prophecy-phpunit where "prophesize" method is provided as a trait [#46](https://github.com/Haehnchen/idea-php-phpunit-plugin/issues/46) (Daniel Espendiller)
21+
* Move to gradle build (Daniel Espendiller)
22+
* Fix for build on travis ([#45](https://github.com/Haehnchen/idea-php-phpunit-plugin/issues/45)) (Roman Tymoshyk)
23+
* Add missing namespaces PhpUnit mock instances (Daniel Espendiller)
24+
825
## 3.8
926
* Fix performance issue: migrate test linemarker runner to leaf elements
1027

src/main/java/de/espend/idea/php/phpunit/completion/PhpUnitCompletionContributor.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
*/
2222
public class PhpUnitCompletionContributor extends CompletionContributor {
2323
public PhpUnitCompletionContributor() {
24-
extend(CompletionType.BASIC, PatternUtil.getMethodReferenceWithParameterInsideTokenStringPattern(), new CompletionProvider<>() {
24+
extend(CompletionType.BASIC, PatternUtil.getMethodReferenceWithParameterInsideTokenStringPattern(), new CompletionProvider<CompletionParameters>() {
2525
@Override
2626
protected void addCompletions(@NotNull CompletionParameters completionParameters, @NotNull ProcessingContext processingContext, @NotNull CompletionResultSet resultSet) {
2727
PsiElement psiElement = completionParameters.getPosition();

src/main/java/de/espend/idea/php/phpunit/type/MockProphecyTypeProvider.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,17 +19,17 @@ public class MockProphecyTypeProvider implements PhpTypeProvider3 {
1919
public static final char CHAR = '元';
2020
public static char TRIM_KEY = '\u0192';
2121

22-
private static final Collection<String> PHPUNIT_CLASSES = new HashSet<>() {{
22+
private static final Collection<String> PHPUNIT_CLASSES = new HashSet<String>() {{
2323
add("\\PHPUnit\\Framework\\TestCase");
2424
add("\\PHPUnit_Framework_TestCase");
2525
}};
2626

27-
private static final Collection<String> PROPHESIZE_CLASSES = new HashSet<>(PHPUNIT_CLASSES) {{
27+
private static final Collection<String> PROPHESIZE_CLASSES = new HashSet<String>(PHPUNIT_CLASSES) {{
2828
add("\\Prophecy\\Prophet");
2929
add("\\Prophecy\\PhpUnit\\ProphecyTrait");
3030
}};
3131

32-
private static final Map<String, Collection<String>> METHODS = new HashMap<>() {{
32+
private static final Map<String, Collection<String>> METHODS = new HashMap<String, Collection<String>>() {{
3333
put("getMock", PHPUNIT_CLASSES);
3434
put("getMockClass", PHPUNIT_CLASSES);
3535
put("getMockForAbstractClass", PHPUNIT_CLASSES);
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
<html>
2+
<ul>
3+
<li>Allow all PhpUnit mock instance in chaining for finding createMock <a href="https://github.com/Haehnchen/idea-php-phpunit-plugin/issues/39">#39</a> (Daniel Espendiller)</li>
4+
<li>Provide support for "PHPUnit\Framework\MockObject\Stub::method" <a href="https://github.com/Haehnchen/idea-php-phpunit-plugin/issues/42">#42</a> <a href="https://github.com/Haehnchen/idea-php-phpunit-plugin/issues/39">#39</a> (Daniel Espendiller)</li>
5+
<li>Dropping feature support for build < 2020.1; api is still valid so by now no build-since highering needed (Daniel Espendiller)</li>
6+
<li>Support also Behat tests file structure (Daniel Espendiller)</li>
7+
<li>Fix isPrimitiveType checking for constructor creation intention (Daniel Espendiller)</li>
8+
<li>Remove deprecated code (Daniel Espendiller)</li>
9+
<li>Remove runner linemarker in favor of already provide by PhpStorm (Daniel Espendiller)</li>
10+
<li>Add plugin icon (Daniel Espendiller)</li>
11+
<li>Allow "setUpBeforeTest" to be a valid "setUp" method for checking property types #35 (Daniel Espendiller)</li>
12+
<li>Allow some more use cases for checking test context eg for Behat <a href="https://github.com/Haehnchen/idea-php-phpunit-plugin/issues/37">#37</a> (Daniel Espendiller)</li>
13+
<li>Add support for phpspec/prophecy-phpunit where "prophesize" method is provided as a trait <a href="https://github.com/Haehnchen/idea-php-phpunit-plugin/issues/46">#46</a> (Daniel Espendiller)</li>
14+
<li>Move to gradle build (Daniel Espendiller)</li>
15+
<li>Fix for build on travis (<a href="https://github.com/Haehnchen/idea-php-phpunit-plugin/issues/45">#45</a>) (Roman Tymoshyk)</li>
16+
<li>Add missing namespaces PhpUnit mock instances (Daniel Espendiller)</li>
17+
</ul>
18+
</html>

src/main/resources/META-INF/plugin.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<idea-plugin url="https://github.com/Haehnchen/idea-php-phpunit-plugin">
22
<id>de.espend.idea.php.phpunit</id>
33
<name>PHPUnit Enhancement</name>
4-
<version>3.8</version>
4+
<version>4.0</version>
55
<vendor email="daniel@espendiller.net" url="http://espend.de">espend_de</vendor>
66

77
<description><![CDATA[

0 commit comments

Comments
 (0)