-
Notifications
You must be signed in to change notification settings - Fork 15
feat/CUS-10801-Migrated the addon to EU Region #341
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
akhil-testsigma
merged 1 commit into
dev
from
feat/CUS-10801-Migrated-the-addon-to-EU-Region
Feb 19, 2026
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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,102 @@ | ||
| <?xml version="1.0" encoding="UTF-8"?> | ||
| <project | ||
| xmlns="http://maven.apache.org/POM/4.0.0" | ||
| xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
| xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> | ||
| <modelVersion>4.0.0</modelVersion> | ||
| <groupId>com.testsigma.addons</groupId> | ||
| <artifactId>convert_date_format</artifactId> | ||
| <version>1.0.0</version> | ||
| <packaging>jar</packaging> | ||
|
|
||
| <properties> | ||
| <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> | ||
| <maven.compiler.source>11</maven.compiler.source> | ||
| <maven.compiler.target>11</maven.compiler.target> | ||
| <testsigma.sdk.version>1.2.24_cloud</testsigma.sdk.version> | ||
| <junit.jupiter.version>5.8.0-M1</junit.jupiter.version> | ||
| <testsigma.addon.maven.plugin>1.0.0</testsigma.addon.maven.plugin> | ||
| <maven.source.plugin.version>3.2.1</maven.source.plugin.version> | ||
| <lombok.version>1.18.30</lombok.version> | ||
|
|
||
| </properties> | ||
|
|
||
| <dependencies> | ||
| <dependency> | ||
| <groupId>com.testsigma</groupId> | ||
| <artifactId>testsigma-java-sdk</artifactId> | ||
| <version>${testsigma.sdk.version}</version> | ||
| </dependency> | ||
| <dependency> | ||
| <groupId>org.projectlombok</groupId> | ||
| <artifactId>lombok</artifactId> | ||
| <version>${lombok.version}</version> | ||
| <optional>true</optional> | ||
| </dependency> | ||
| <dependency> | ||
| <groupId>org.junit.jupiter</groupId> | ||
| <artifactId>junit-jupiter-api</artifactId> | ||
| <version>${junit.jupiter.version}</version> | ||
| <scope>test</scope> | ||
| </dependency> | ||
| <dependency> | ||
| <groupId>org.testng</groupId> | ||
| <artifactId>testng</artifactId> | ||
| <version>6.14.3</version> | ||
| </dependency> | ||
| <!-- https://mvnrepository.com/artifact/org.seleniumhq.selenium/selenium-java --> | ||
| <dependency> | ||
| <groupId>org.seleniumhq.selenium</groupId> | ||
| <artifactId>selenium-java</artifactId> | ||
| <version>4.33.0</version> | ||
| </dependency> | ||
| <!-- https://mvnrepository.com/artifact/io.appium/java-client --> | ||
| <dependency> | ||
| <groupId>io.appium</groupId> | ||
| <artifactId>java-client</artifactId> | ||
| <version>9.4.0</version> | ||
| </dependency> | ||
| <dependency> | ||
| <groupId>com.fasterxml.jackson.core</groupId> | ||
| <artifactId>jackson-annotations</artifactId> | ||
| <version>2.13.0</version> | ||
| </dependency> | ||
| <dependency> | ||
| <groupId>org.apache.commons</groupId> | ||
| <artifactId>commons-lang3</artifactId> | ||
| <version>3.14.0</version> | ||
| </dependency> | ||
|
|
||
| </dependencies> | ||
| <build> | ||
| <finalName>convert_date_format</finalName> | ||
| <plugins> | ||
| <plugin> | ||
| <groupId>org.apache.maven.plugins</groupId> | ||
| <artifactId>maven-shade-plugin</artifactId> | ||
| <version>3.2.4</version> | ||
| <executions> | ||
| <execution> | ||
| <phase>package</phase> | ||
| <goals> | ||
| <goal>shade</goal> | ||
| </goals> | ||
| </execution> | ||
| </executions> | ||
| </plugin> | ||
| <plugin> | ||
| <groupId>org.apache.maven.plugins</groupId> | ||
| <artifactId>maven-source-plugin</artifactId> | ||
| <version>${maven.source.plugin.version}</version> | ||
| <executions> | ||
| <execution> | ||
| <id>attach-sources</id> | ||
| <goals> | ||
| <goal>jar</goal> | ||
| </goals> | ||
| </execution> | ||
| </executions> | ||
| </plugin> | ||
| </plugins> | ||
| </build> | ||
| </project> |
74 changes: 74 additions & 0 deletions
74
convert_date_format/src/main/java/com/testsigma/addons/android/DateFormatConversion.java
This file contains hidden or 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,74 @@ | ||
| package com.testsigma.addons.android; | ||
|
|
||
| import com.testsigma.sdk.AndroidAction; | ||
| import com.testsigma.sdk.ApplicationType; | ||
| import com.testsigma.sdk.Result; | ||
| import com.testsigma.sdk.WebAction; | ||
| import com.testsigma.sdk.annotation.Action; | ||
| import com.testsigma.sdk.annotation.RunTimeData; | ||
| import com.testsigma.sdk.annotation.TestData; | ||
| import lombok.Data; | ||
| import org.apache.commons.lang3.exception.ExceptionUtils; | ||
| import org.openqa.selenium.NoSuchElementException; | ||
|
|
||
| import java.text.SimpleDateFormat; | ||
| import java.util.Date; | ||
|
|
||
| @Data | ||
| @Action(actionText = "Convert the date from the testdata in format1 to format2 and store it in a runtime variable", | ||
| description = "To store the number of char from testdata into runtime variable", | ||
| applicationType = ApplicationType.ANDROID) | ||
|
|
||
| public class DateFormatConversion extends AndroidAction | ||
| { | ||
|
|
||
| @TestData(reference = "testdata") | ||
| private com.testsigma.sdk.TestData testData1; | ||
|
|
||
| @TestData(reference = "format1") | ||
| private com.testsigma.sdk.TestData testData2; | ||
|
|
||
| @TestData(reference = "format2") | ||
| private com.testsigma.sdk.TestData testData3; | ||
|
|
||
| @TestData(reference = "variable") | ||
| private com.testsigma.sdk.TestData runtimeVar; | ||
|
|
||
| @RunTimeData | ||
| private com.testsigma.sdk.RunTimeData runTimeData; | ||
|
|
||
| @Override | ||
| public Result execute() throws NoSuchElementException | ||
| { | ||
| //Your Awesome code starts here | ||
| logger.info("Initiating execution"); | ||
| Result result = Result.SUCCESS; | ||
|
|
||
| try { | ||
| SimpleDateFormat inputFormat = new SimpleDateFormat(testData2.getValue().toString()); | ||
| SimpleDateFormat outputFormat = new SimpleDateFormat(testData3.getValue().toString()); | ||
| logger.info("testdata = " + testData1.getValue().toString()); | ||
| logger.info("format1 = " + testData2.getValue().toString()); | ||
| logger.info("format2 = " + testData3.getValue().toString()); | ||
| logger.info("variable = " + runtimeVar.getValue().toString()); | ||
|
|
||
| String inputDateString = testData1.getValue().toString(); | ||
| Date parsedDate = inputFormat.parse(inputDateString); | ||
|
|
||
| String outputDateString = outputFormat.format(parsedDate); | ||
| logger.info("outputDateString = " + outputDateString); | ||
|
|
||
| runTimeData.setKey(runtimeVar.getValue().toString()); | ||
| runTimeData.setValue(outputDateString); | ||
|
|
||
| logger.info("Successfully converted date from " + testData2.getValue().toString() + " to " + testData3.getValue().toString() + " and stored in runtime variable = " +outputDateString); | ||
| setSuccessMessage("Successfully converted date from " + testData2.getValue().toString() + " to " + testData3.getValue().toString() + " and stored in runtime variable = " +outputDateString); | ||
| } catch(Exception e) { | ||
| logger.warn("Operation failed , the error message is ::::"+ ExceptionUtils.getStackTrace(e)); | ||
| setErrorMessage("Operation failed , the error message is ::::"+ ExceptionUtils.getMessage(e)); | ||
| result = Result.FAILED; | ||
| } | ||
| return result; | ||
| } | ||
| } | ||
|
|
71 changes: 71 additions & 0 deletions
71
convert_date_format/src/main/java/com/testsigma/addons/ios/DateFormatConversion.java
This file contains hidden or 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,71 @@ | ||
| package com.testsigma.addons.ios; | ||
|
|
||
| import com.testsigma.sdk.*; | ||
| import com.testsigma.sdk.annotation.Action; | ||
| import com.testsigma.sdk.annotation.RunTimeData; | ||
| import com.testsigma.sdk.annotation.TestData; | ||
| import lombok.Data; | ||
| import org.apache.commons.lang3.exception.ExceptionUtils; | ||
| import org.openqa.selenium.NoSuchElementException; | ||
| import org.openqa.selenium.devtools.v135.io.IO; | ||
|
|
||
| import java.text.SimpleDateFormat; | ||
| import java.util.Date; | ||
|
|
||
| @Data | ||
| @Action(actionText = "Convert the date from the testdata in format1 to format2 and store it in a runtime variable", | ||
| description = "To store the number of char from testdata into runtime variable", | ||
| applicationType = ApplicationType.IOS) | ||
|
|
||
| public class DateFormatConversion extends IOSAction { | ||
|
|
||
| @TestData(reference = "testdata") | ||
| private com.testsigma.sdk.TestData testData1; | ||
|
|
||
| @TestData(reference = "format1") | ||
| private com.testsigma.sdk.TestData testData2; | ||
|
|
||
| @TestData(reference = "format2") | ||
| private com.testsigma.sdk.TestData testData3; | ||
|
|
||
| @TestData(reference = "variable") | ||
| private com.testsigma.sdk.TestData runtimeVar; | ||
|
|
||
| @RunTimeData | ||
| private com.testsigma.sdk.RunTimeData runTimeData; | ||
|
|
||
| @Override | ||
| public Result execute() throws NoSuchElementException | ||
| { | ||
| //Your Awesome code starts here | ||
| logger.info("Initiating execution"); | ||
| Result result = Result.SUCCESS; | ||
|
|
||
| try { | ||
| SimpleDateFormat inputFormat = new SimpleDateFormat(testData2.getValue().toString()); | ||
| SimpleDateFormat outputFormat = new SimpleDateFormat(testData3.getValue().toString()); | ||
| logger.info("testdata = " + testData1.getValue().toString()); | ||
| logger.info("format1 = " + testData2.getValue().toString()); | ||
| logger.info("format2 = " + testData3.getValue().toString()); | ||
| logger.info("variable = " + runtimeVar.getValue().toString()); | ||
|
|
||
| String inputDateString = testData1.getValue().toString(); | ||
| Date parsedDate = inputFormat.parse(inputDateString); | ||
|
|
||
| String outputDateString = outputFormat.format(parsedDate); | ||
| logger.info("outputDateString = " + outputDateString); | ||
|
|
||
| runTimeData.setKey(runtimeVar.getValue().toString()); | ||
| runTimeData.setValue(outputDateString); | ||
|
|
||
| logger.info("Successfully converted date from " + testData2.getValue().toString() + " to " + testData3.getValue().toString() + " and stored in runtime variable = " +outputDateString); | ||
| setSuccessMessage("Successfully converted date from " + testData2.getValue().toString() + " to " + testData3.getValue().toString() + " and stored in runtime variable = " +outputDateString); | ||
| } catch(Exception e) { | ||
| logger.warn("Operation failed , the error message is ::::"+ ExceptionUtils.getStackTrace(e)); | ||
| setErrorMessage("Operation failed , the error message is ::::"+ ExceptionUtils.getMessage(e)); | ||
| result = Result.FAILED; | ||
| } | ||
| return result; | ||
| } | ||
| } | ||
|
|
||
74 changes: 74 additions & 0 deletions
74
convert_date_format/src/main/java/com/testsigma/addons/mobileweb/DateFormatConversion.java
This file contains hidden or 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,74 @@ | ||
| package com.testsigma.addons.mobileweb; | ||
|
|
||
| import com.testsigma.sdk.AndroidAction; | ||
| import com.testsigma.sdk.ApplicationType; | ||
| import com.testsigma.sdk.Result; | ||
| import com.testsigma.sdk.WebAction; | ||
| import com.testsigma.sdk.annotation.Action; | ||
| import com.testsigma.sdk.annotation.RunTimeData; | ||
| import com.testsigma.sdk.annotation.TestData; | ||
| import lombok.Data; | ||
| import org.apache.commons.lang3.exception.ExceptionUtils; | ||
| import org.openqa.selenium.NoSuchElementException; | ||
|
|
||
| import java.text.SimpleDateFormat; | ||
| import java.util.Date; | ||
|
|
||
| @Data | ||
| @Action(actionText = "Convert the date from the testdata in format1 to format2 and store it in a runtime variable", | ||
| description = "To store the number of char from testdata into runtime variable", | ||
| applicationType = ApplicationType.MOBILE_WEB) | ||
|
|
||
| public class DateFormatConversion extends WebAction | ||
| { | ||
|
|
||
| @TestData(reference = "testdata") | ||
| private com.testsigma.sdk.TestData testData1; | ||
|
|
||
| @TestData(reference = "format1") | ||
| private com.testsigma.sdk.TestData testData2; | ||
|
|
||
| @TestData(reference = "format2") | ||
| private com.testsigma.sdk.TestData testData3; | ||
|
|
||
| @TestData(reference = "variable") | ||
| private com.testsigma.sdk.TestData runtimeVar; | ||
|
|
||
| @RunTimeData | ||
| private com.testsigma.sdk.RunTimeData runTimeData; | ||
|
|
||
| @Override | ||
| public Result execute() throws NoSuchElementException | ||
| { | ||
| //Your Awesome code starts here | ||
| logger.info("Initiating execution"); | ||
| Result result = Result.SUCCESS; | ||
|
|
||
| try { | ||
| SimpleDateFormat inputFormat = new SimpleDateFormat(testData2.getValue().toString()); | ||
| SimpleDateFormat outputFormat = new SimpleDateFormat(testData3.getValue().toString()); | ||
| logger.info("testdata = " + testData1.getValue().toString()); | ||
| logger.info("format1 = " + testData2.getValue().toString()); | ||
| logger.info("format2 = " + testData3.getValue().toString()); | ||
| logger.info("variable = " + runtimeVar.getValue().toString()); | ||
|
|
||
| String inputDateString = testData1.getValue().toString(); | ||
| Date parsedDate = inputFormat.parse(inputDateString); | ||
|
|
||
| String outputDateString = outputFormat.format(parsedDate); | ||
| logger.info("outputDateString = " + outputDateString); | ||
|
|
||
| runTimeData.setKey(runtimeVar.getValue().toString()); | ||
| runTimeData.setValue(outputDateString); | ||
|
|
||
| logger.info("Successfully converted date from " + testData2.getValue().toString() + " to " + testData3.getValue().toString() + " and stored in runtime variable = " +outputDateString); | ||
| setSuccessMessage("Successfully converted date from " + testData2.getValue().toString() + " to " + testData3.getValue().toString() + " and stored in runtime variable = " +outputDateString); | ||
| } catch(Exception e) { | ||
| logger.warn("Operation failed , the error message is ::::"+ ExceptionUtils.getStackTrace(e)); | ||
| setErrorMessage("Operation failed , the error message is ::::"+ ExceptionUtils.getMessage(e)); | ||
| result = Result.FAILED; | ||
| } | ||
| return result; | ||
| } | ||
| } | ||
|
|
71 changes: 71 additions & 0 deletions
71
convert_date_format/src/main/java/com/testsigma/addons/restapi/DateFormatConversion.java
This file contains hidden or 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,71 @@ | ||
| package com.testsigma.addons.restapi; | ||
|
|
||
| import com.testsigma.sdk.*; | ||
| import com.testsigma.sdk.annotation.Action; | ||
| import com.testsigma.sdk.annotation.RunTimeData; | ||
| import com.testsigma.sdk.annotation.TestData; | ||
| import lombok.Data; | ||
| import org.apache.commons.lang3.exception.ExceptionUtils; | ||
| import org.openqa.selenium.NoSuchElementException; | ||
|
|
||
| import java.text.SimpleDateFormat; | ||
| import java.util.Date; | ||
|
|
||
| @Data | ||
| @Action(actionText = "Convert the date from the testdata in format1 to format2 and store it in a runtime variable", | ||
| description = "To store the number of char from testdata into runtime variable", | ||
| applicationType = ApplicationType.REST_API) | ||
|
|
||
| public class DateFormatConversion extends RestApiAction | ||
| { | ||
|
|
||
| @TestData(reference = "testdata") | ||
| private com.testsigma.sdk.TestData testData1; | ||
|
|
||
| @TestData(reference = "format1") | ||
| private com.testsigma.sdk.TestData testData2; | ||
|
|
||
| @TestData(reference = "format2") | ||
| private com.testsigma.sdk.TestData testData3; | ||
|
|
||
| @TestData(reference = "variable") | ||
| private com.testsigma.sdk.TestData runtimeVar; | ||
|
|
||
| @RunTimeData | ||
| private com.testsigma.sdk.RunTimeData runTimeData; | ||
|
|
||
| @Override | ||
| public Result execute() throws NoSuchElementException | ||
| { | ||
| //Your Awesome code starts here | ||
| logger.info("Initiating execution"); | ||
| Result result = Result.SUCCESS; | ||
|
|
||
| try { | ||
| SimpleDateFormat inputFormat = new SimpleDateFormat(testData2.getValue().toString()); | ||
| SimpleDateFormat outputFormat = new SimpleDateFormat(testData3.getValue().toString()); | ||
| logger.info("testdata = " + testData1.getValue().toString()); | ||
| logger.info("format1 = " + testData2.getValue().toString()); | ||
| logger.info("format2 = " + testData3.getValue().toString()); | ||
| logger.info("variable = " + runtimeVar.getValue().toString()); | ||
|
|
||
| String inputDateString = testData1.getValue().toString(); | ||
| Date parsedDate = inputFormat.parse(inputDateString); | ||
|
|
||
| String outputDateString = outputFormat.format(parsedDate); | ||
| logger.info("outputDateString = " + outputDateString); | ||
|
|
||
| runTimeData.setKey(runtimeVar.getValue().toString()); | ||
| runTimeData.setValue(outputDateString); | ||
|
|
||
| logger.info("Successfully converted date from " + testData2.getValue().toString() + " to " + testData3.getValue().toString() + " and stored in runtime variable = " +outputDateString); | ||
| setSuccessMessage("Successfully converted date from " + testData2.getValue().toString() + " to " + testData3.getValue().toString() + " and stored in runtime variable = " +outputDateString); | ||
| } catch(Exception e) { | ||
| logger.warn("Operation failed , the error message is ::::"+ ExceptionUtils.getStackTrace(e)); | ||
| setErrorMessage("Operation failed , the error message is ::::"+ ExceptionUtils.getMessage(e)); | ||
| result = Result.FAILED; | ||
| } | ||
| return result; | ||
| } | ||
| } | ||
|
|
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Inaccurate
description— applies to all 6 platform files.The description says "To store the number of char from testdata into runtime variable" which describes a character-count action, not a date format conversion. This text is user-facing in the Testsigma UI and will mislead users.
Proposed fix
📝 Committable suggestion
🤖 Prompt for AI Agents