Faker Actions related to App
appName
Description: This function will generate a random application name
Input Format : DatasheetName:ColumnName
ObjectName | Action | Input | Condition | Reference | |
---|---|---|---|---|---|
Synthetic Data | appName |
DatasheetName:ColumnName |
@Action(object = ObjectType.FAKER, desc = "Generate a random application name", input = InputType.YES, condition = InputType.NO)
public void appName() {
try {
String strObj = Input;
String appName = faker.get(key).app().name();
Report.updateTestLog(Action, "Generated data: " + appName, Status.DONE);
String sheetName = strObj.split(":", 2)[0];
String columnName = strObj.split(":", 2)[1];
userData.putData(sheetName, columnName, appName);
} catch (Exception ex) {
Logger.getLogger(this.getClass().getName()).log(Level.SEVERE, "Exception during data generation", ex);
Report.updateTestLog(Action, "Error generating data: " + "\n" + ex.getMessage(), Status.DEBUG);
}
}
appVersion
Description: This function will generate a random application version
Input Format : DatasheetName:ColumnName
ObjectName | Action | Input | Condition | Reference | |
---|---|---|---|---|---|
Synthetic Data | appVersion |
DatasheetName:ColumnName |
@Action(object = ObjectType.FAKER, desc = "Generate a random application version", input = InputType.YES, condition = InputType.NO)
public void appVersion() {
try {
String strObj = Input;
String appVersion = faker.get(key).app().version();
Report.updateTestLog(Action, "Generated data: " + appVersion, Status.DONE);
String sheetName = strObj.split(":", 2)[0];
String columnName = strObj.split(":", 2)[1];
userData.putData(sheetName, columnName, appVersion);
} catch (Exception ex) {
Logger.getLogger(this.getClass().getName()).log(Level.SEVERE, "Exception during data generation", ex);
Report.updateTestLog(Action, "Error generating data: " + "\n" + ex.getMessage(), Status.DEBUG);
}
}
appAuthor
Description: This function will generate a random application author
Input Format : DatasheetName:ColumnName
ObjectName | Action | Input | Condition | Reference | |
---|---|---|---|---|---|
Synthetic Data | appAuthor |
DatasheetName:ColumnName |
@Action(object = ObjectType.FAKER, desc = "Generate a random application author", input = InputType.YES, condition = InputType.NO)
public void appAuthor() {
try {
String strObj = Input;
String appAuthor = faker.get(key).app().author();
Report.updateTestLog(Action, "Generated data: " + appAuthor, Status.DONE);
String sheetName = strObj.split(":", 2)[0];
String columnName = strObj.split(":", 2)[1];
userData.putData(sheetName, columnName, appAuthor);
} catch (Exception ex) {
Logger.getLogger(this.getClass().getName()).log(Level.SEVERE, "Exception during data generation", ex);
Report.updateTestLog(Action, "Error generating data: " + "\n" + ex.getMessage(), Status.DEBUG);
}
}