-
Notifications
You must be signed in to change notification settings - Fork 30
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #238 from reportportal/develop
Release
- Loading branch information
Showing
20 changed files
with
534 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
38 changes: 38 additions & 0 deletions
38
src/main/java/com/epam/reportportal/annotations/Description.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
/* | ||
* Copyright 2024 EPAM Systems | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* https://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
package com.epam.reportportal.annotations; | ||
|
||
import java.lang.annotation.ElementType; | ||
import java.lang.annotation.Retention; | ||
import java.lang.annotation.RetentionPolicy; | ||
import java.lang.annotation.Target; | ||
|
||
/** | ||
* If put on a method or constructor, or class, overrides or set corresponding Test Item description on ReportPortal. | ||
* This annotation should be handled in priority to other mechanisms of existing test frameworks. | ||
*/ | ||
@Retention(RetentionPolicy.RUNTIME) | ||
@Target({ ElementType.METHOD, ElementType.TYPE }) | ||
public @interface Description { | ||
|
||
/** | ||
* Test Item description as a simple String. | ||
* | ||
* @return new description for a Test Item | ||
*/ | ||
String value(); | ||
} |
38 changes: 38 additions & 0 deletions
38
src/main/java/com/epam/reportportal/annotations/DisplayName.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
/* | ||
* Copyright 2024 EPAM Systems | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* https://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
package com.epam.reportportal.annotations; | ||
|
||
import java.lang.annotation.ElementType; | ||
import java.lang.annotation.Retention; | ||
import java.lang.annotation.RetentionPolicy; | ||
import java.lang.annotation.Target; | ||
|
||
/** | ||
* If put on a method or constructor, or class, overrides corresponding Test Item name on ReportPortal. | ||
* This annotation should be handled in priority to other mechanisms of existing test frameworks. | ||
*/ | ||
@Retention(RetentionPolicy.RUNTIME) | ||
@Target({ ElementType.METHOD, ElementType.TYPE }) | ||
public @interface DisplayName { | ||
|
||
/** | ||
* Test Item name as a simple String. | ||
* | ||
* @return new name for a Test Item | ||
*/ | ||
String value(); | ||
} |
60 changes: 60 additions & 0 deletions
60
src/main/java/com/epam/reportportal/annotations/ExternalIssue.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
/* | ||
* Copyright 2024 EPAM Systems | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* https://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
package com.epam.reportportal.annotations; | ||
|
||
import java.lang.annotation.Documented; | ||
import java.lang.annotation.Retention; | ||
import java.lang.annotation.RetentionPolicy; | ||
import java.lang.annotation.Target; | ||
|
||
/** | ||
* Link current Issue with an Issue posted in External Bug Tracking System. This annotation designed to use within {@link Issue} annotation | ||
* only and does not allow to add it to any other target. | ||
*/ | ||
@Documented | ||
@Retention(RetentionPolicy.RUNTIME) | ||
@Target({}) | ||
public @interface ExternalIssue { | ||
/** | ||
* External System Issue ID | ||
* | ||
* @return Issue ID | ||
*/ | ||
String value(); | ||
|
||
/** | ||
* Optional, use custom Bug Tracking System URL instead of one which is set in `reportportal.properties` file. | ||
* | ||
* @return Bug Tracking System URL | ||
*/ | ||
String btsUrl() default ""; | ||
|
||
/** | ||
* Optional, use custom Bug Tracking System Project name instead of one which is set in `reportportal.properties` file. | ||
* | ||
* @return Bug Tracking System Project name | ||
*/ | ||
String btsProject() default ""; | ||
|
||
/** | ||
* Optional, use custom Bug Tracking System Issue URL pattern instead of one which is set in `reportportal.properties` file. Use | ||
* <code>{issue_id}</code> mark to put it into the result URL. | ||
* | ||
* @return Bug Tracking System Issue URL pattern | ||
*/ | ||
String urlPattern() default ""; | ||
} |
60 changes: 60 additions & 0 deletions
60
src/main/java/com/epam/reportportal/annotations/Issue.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
/* | ||
* Copyright 2024 EPAM Systems | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* https://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
package com.epam.reportportal.annotations; | ||
|
||
import java.lang.annotation.*; | ||
|
||
/** | ||
* This annotation supposed to automatically link failed test items a specific Issue on ReportPortal. | ||
*/ | ||
@Documented | ||
@Inherited | ||
@Retention(RetentionPolicy.RUNTIME) | ||
@Target(ElementType.METHOD) | ||
@Repeatable(Issues.class) | ||
public @interface Issue { | ||
/** | ||
* Type (Locator), Short Name (Abbreviation) or Long Name (Defect name) (specified by priority) of an Issue on ReportPortal for | ||
* the current project. If there is no such issue found in Project Setting the value will be used "as is" and sent as | ||
* Issue Type (Locator). | ||
* | ||
* @return Type (Locator), Short Name (Abbreviation) or Long Name (Defect name) of an Issue | ||
*/ | ||
String value(); | ||
|
||
/** | ||
* Arbitrary text describing the issue. | ||
* | ||
* @return issue description | ||
*/ | ||
String comment() default ""; | ||
|
||
/** | ||
* Links to External System where this issue is located. | ||
* | ||
* @return External Issue describing object | ||
*/ | ||
ExternalIssue[] external() default {}; | ||
|
||
/** | ||
* For Parameterized and Dynamic tests select certain test for Issue applying using filters by certain criteria. Each additional filter | ||
* applies to the set of tests using logical "AND". | ||
* | ||
* @return filter list | ||
*/ | ||
TestFilter[] filter() default {}; | ||
} |
30 changes: 30 additions & 0 deletions
30
src/main/java/com/epam/reportportal/annotations/Issues.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
/* | ||
* Copyright 2024 EPAM Systems | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* https://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
package com.epam.reportportal.annotations; | ||
|
||
import java.lang.annotation.*; | ||
|
||
/** | ||
* Gathering annotation for {@link Issue} | ||
*/ | ||
@Documented | ||
@Inherited | ||
@Retention(RetentionPolicy.RUNTIME) | ||
@Target(ElementType.METHOD) | ||
public @interface Issues { | ||
Issue[] value(); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
45 changes: 45 additions & 0 deletions
45
src/main/java/com/epam/reportportal/annotations/TestFilter.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
/* | ||
* Copyright 2024 EPAM Systems | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* https://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
package com.epam.reportportal.annotations; | ||
|
||
import java.lang.annotation.Documented; | ||
import java.lang.annotation.Retention; | ||
import java.lang.annotation.RetentionPolicy; | ||
import java.lang.annotation.Target; | ||
|
||
/** | ||
* Link current Issue with a specific Parameterized or Dynamic test by applying filters. | ||
*/ | ||
@Documented | ||
@Retention(RetentionPolicy.RUNTIME) | ||
@Target({}) | ||
public @interface TestFilter { | ||
|
||
/** | ||
* Specify Test Name filters to select certain test for {@link Issue} applying, suitable for dynamic tests. | ||
* | ||
* @return Test Name filters | ||
*/ | ||
TestNameFilter[] name() default {}; | ||
|
||
/** | ||
* Specify Test Parameter filters to select certain test for {@link Issue} applying, suitable for parameterized tests. | ||
* | ||
* @return Test Name filters | ||
*/ | ||
TestParamFilter[] param() default {}; | ||
} |
43 changes: 43 additions & 0 deletions
43
src/main/java/com/epam/reportportal/annotations/TestNameFilter.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
/* | ||
* Copyright 2024 EPAM Systems | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* https://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
package com.epam.reportportal.annotations; | ||
|
||
/** | ||
* Filter Test Set by Test Name. | ||
*/ | ||
public @interface TestNameFilter { | ||
/** | ||
* Select a test which name starts with specified String. | ||
* | ||
* @return required prefix | ||
*/ | ||
String startsWith() default ""; | ||
|
||
/** | ||
* Select a test which name ends with specified String. | ||
* | ||
* @return required postfix | ||
*/ | ||
String endsWith() default ""; | ||
|
||
/** | ||
* Select a test which name should contain specified String. | ||
* | ||
* @return required contents | ||
*/ | ||
String contains() default ""; | ||
} |
Oops, something went wrong.