Skip to content
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

fix: Module certification issues #231

Open
wants to merge 9 commits into
base: dev
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions cypress/TestCases/FireboltCertification/Advertising.feature
Original file line number Diff line number Diff line change
Expand Up @@ -113,9 +113,8 @@ Feature: Advertising
@sdk @transport
Scenario Outline: Advertising.advertisingId - Positive Scenario: <Scenario>
When 1st party app invokes the 'Firebolt' API to '<MANAGE_API_Key>'
And '3rd party app' invokes the 'Firebolt' API to '<CORE_API_Key>'
Then 'Firebolt' platform responds to '1st party app' with '<MANAGE_API_Key>'
When '3rd party app' invokes the 'Firebolt' API to '<CORE_API_Key>'
And '3rd party app' invokes the 'Firebolt' API to '<CORE_API_Key>'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be 'When' keyword. Do. not understand why it was changed to 'And'

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

review comment addresed

Then 'Firebolt' platform responds with '<Validation_key>'

Examples:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ Feature: Localization
| Set & get Language en | language | en |
| Set & get preferredAudioLanguages(spa-eng) | preferredAudioLanguages | spa,eng |
| Set & get preferredAudioLanguages(eng-spa) | preferredAudioLanguages | eng,spa |
| Set & get PostalCode | postalCode | 12345 |
| Set & get PostalCode | postalCode | "12345" |

@regression @sdk @requiresPlatformImplementation
Scenario Outline: Localization.<Method_Name> - Positive Scenario: Clearing event listeners
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ Feature: ClosedCaptions_Manage
| Set fontSize-true | fontSize | true | INVALID_TYPE_PARAMS |
| Set fontSize-test | fontSize | test | INVALID_TYPE_PARAMS |
| Set fontSize-true | fontSize | true | INVALID_TYPE_PARAMS |
| Set fontSize-0.25 | fontSize | 0.25 | INVALID_TYPE_PARAMS |
| Set fontSize-0.25 | fontSize | 0.25 | INVALID_PARAMS |
| Set fontFamily-sans-serif | fontFamily | sans-serif | INVALID_TYPE_PARAMS |
| Set fontEdge-123 | fontEdge | 123 | INVALID_TYPE_PARAMS |
| Set fontEdge-true | fontEdge | true | INVALID_TYPE_PARAMS |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ Feature: Localization_Manage
Examples:
| Scenario | Method | Value |
| Locality | locality | washington |
| PostalCode | postalCode | 123456 |
| PostalCode | postalCode | "123456" |
| CountryCode | countryCode | PH |
| Language es | language | es |
| Language en | language | en |
Expand Down
12 changes: 6 additions & 6 deletions cypress/fixtures/fireboltCalls/securestorage.js
Original file line number Diff line number Diff line change
Expand Up @@ -105,12 +105,12 @@ exports.STATIC_VARIABLES = {
SET_DEVICE1: {
scope: 'device',
key: 'authTestTokenDevice1',
value: 'authTestTokenDevice1',
value: 'authTestTokenDeviceValue1',
},
SET_DEVICE2: {
scope: 'device',
key: 'authTestTokenDevice2',
value: 'authTestTokenDevice2',
value: 'authTestTokenDeviceValue2',
},
SET_ACCOUNT1: {
scope: 'account',
Expand Down Expand Up @@ -302,10 +302,10 @@ exports.STATIC_VARIABLES = {
SECURESTORAGE_CONTENT: {
DEFAULT_VALUE: 'VGhpcyBub3QgYSByZWFsIHRva2VuLgo=',
VALUE1: 'authTestTokenValue1',
GET_DEVICE2: 'authTestTokenDevice2',
GET_ACCOUNT2: 'authTestTokenValue2',
GET_DEVICE1: 'authTestTokenDevice1',
GET_ACCOUNT1: 'authTestTokenAccount1',
GET_DEVICE2: 'authTestTokenDeviceValue2',
GET_ACCOUNT2: 'authTestTokenAccountValue2',
GET_DEVICE1: 'authTestTokenDeviceValue1',
GET_ACCOUNT1: 'authTestTokenAccountValue1',
VALUE2: 'authTestTokenValue2',
VALUE_TTL: 'authTestTokenValueTTL',
SCOPE_UPDATED_VALUE: 'VGhpcyBpcyBub3QgYSByZWFsIHRva2VuLg==',
Expand Down
3 changes: 3 additions & 0 deletions cypress/fixtures/objects/errorContentObjects.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,3 +27,6 @@ exports.NOT_AVAILABLE = {
exports.INVALID_TYPE_PARAMS = {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we removed 'INVALID_TYPE_PARAMS' We can probably remove this Export Also.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

review comment addresed

type: 'schemaOnly',
};
exports.INVALID_PARAMS = {
type: 'schemaOnly',
};
4 changes: 4 additions & 0 deletions cypress/fixtures/objects/errorContentObjects.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,9 @@
},
"INVALID_TYPE_PARAMS": {
"type": "schemaOnly"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you can remove INVALID_TYPE_PARAMS

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

review comment addresed

},
"INVALID_PARAMS": {
"type": "schemaOnly"
}

}
1 change: 1 addition & 0 deletions cypress/support/constants/constants.js
Original file line number Diff line number Diff line change
Expand Up @@ -236,6 +236,7 @@ module.exports = {
LIFECYCLE_HISTORY_FAILED: 'Failed to fetch lifecycle history due to following error: ',
LIFECYCLE_HISTORY_RESPONSE: 'Lifecycle history response fetched from application: ',
LIFECYCLE_HISTORY_SCHEMA_PATH: 'schemas/lifecycleHistorySchema',
LIFECYCLE_HISTORY_INTENT: 'Lifecycle intent sent to application to fetch App history: ',
LIFECYCLE_INTENT: 'Lifecycle intent sent to application: ',
LIFECYCLE_METHOD_LIST: ['Lifecycle.ready', 'Lifecycle.state', 'Lifecycle.close'],
LIFECYCLE_NOTIFICATION_GENERATED: 'Lifecycle events generated ',
Expand Down
2 changes: 1 addition & 1 deletion cypress/support/cypress-commands/assertion.js
Original file line number Diff line number Diff line change
Expand Up @@ -559,7 +559,7 @@ Cypress.Commands.add(
pretext =
pretext +
' for ' +
extractEventObject.eventName +
extractEventObject.eventObjectId +
':' +
' expected ' +
actual +
Expand Down
14 changes: 13 additions & 1 deletion cypress/support/cypress-commands/lifecycle.js
Original file line number Diff line number Diff line change
Expand Up @@ -293,7 +293,19 @@ Cypress.Commands.add('invokeLifecycleApi', (appId, method, methodParams = null)
params,
additionalParams
);
cy.log(CONSTANTS.LIFECYCLE_INTENT + JSON.stringify(publishMessage));

let publishMessageForLog;
if (publishMessage && publishMessage.data && publishMessage.data.query) {
publishMessageForLog = publishMessage.data.query;
if (typeof publishMessageForLog == 'string') {
publishMessageForLog = JSON.parse(publishMessageForLog);
}
if (publishMessageForLog.params.methodName == 'Lifecycle.history') {
cy.log(CONSTANTS.LIFECYCLE_HISTORY_INTENT + JSON.stringify(publishMessage));
} else {
cy.log(CONSTANTS.LIFECYCLE_INTENT + JSON.stringify(publishMessage));
}
}
neeradanelxsi marked this conversation as resolved.
Show resolved Hide resolved
cy.sendMessagetoApp(requestTopic, responseTopic, publishMessage).then((response) => {
try {
errorObject = JSON.parse(response).error;
Expand Down
2 changes: 1 addition & 1 deletion cypress/support/validations/undefinedValidation.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ Cypress.Commands.add(
: null;
const methodOrEventName =
validationType == CONSTANTS.EVENT
? apiOrEventObject.eventName
? apiOrEventObject.eventObjectId
: validationType == CONSTANTS.METHOD
? apiOrEventObject.apiName
: null;
Expand Down
Loading