Skip to content

Comments

[Internal review] Scripts for 3309 issue#190

Open
GetmanetsIrina wants to merge 6 commits intodevelopfrom
defects/3309
Open

[Internal review] Scripts for 3309 issue#190
GetmanetsIrina wants to merge 6 commits intodevelopfrom
defects/3309

Conversation

@GetmanetsIrina
Copy link

ATF Test Scripts to check #FORDTCN-12021

This PR is ready for internal review.

Summary

Scripts to check cutting off parameters from HMI response/notification if app has less version then parameter version

ATF version

develop

Changelog

  • added new scripts
  • added created scripts to 6_1 test set

CLA

@GetmanetsIrina GetmanetsIrina requested a review from VjKlepikov June 7, 2022 13:16
@GetmanetsIrina GetmanetsIrina changed the title [Internal review] Script for 3309 issue [Internal review] Scripts for 3309 issue Jun 7, 2022
runner.Step("Clean environment", common.preconditions)
runner.Step("Start SDL, HMI, connect Mobile, start Session", common.start)
runner.Step("Register App", common.registerApp)
runner.Step("PTU", common.policyTableUpdate, { common.pTUpdateFunc })

Choose a reason for hiding this comment

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

I propose to remove the redundant step common.policyTableUpdate, common.pTUpdateFunc = nil
Seems policy is updated in preconditions

---------------------------------------------------------------------------------------------------
--Issue: https://github.com/smartdevicelink/sdl_core/issues/3309
---------------------------------------------------------------------------------------------------
-- Description: SDL resends the parameter from HMI to mobile app in case app version is greather then parameter version,

Choose a reason for hiding this comment

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

Suggested change
-- Description: SDL resends the parameter from HMI to mobile app in case app version is greather then parameter version,
-- Description: SDL resends the parameter from HMI to mobile app in case app version is greater then parameter version,

for subKey, subValue in pairs (value.params) do
if subValue.name == "shifted" then
-- shifted has since="6.0" in API
pTbl.policy_table.vehicle_data.schema_items[key].params[subKey].since = "7.0.0"

Choose a reason for hiding this comment

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

Should we use since = "7.0" instead of 7.0.0 according to common style in preloaded.pt

Comment on lines 41 to 47
elseif key == #value.params then
common.cprint(35, "'shifted' was not found in preloaded file")
end
end
elseif key == #pTbl.policy_table.vehicle_data.schema_items then
common.cprint(35, parameter .. " was not found in preloaded file")
end

Choose a reason for hiding this comment

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

Seems it not working in case the parameter is absent in sdl_preloaded_pt.json
I propose to add a parameter in case not found

mandatory = false,
minvalue = 0,
maxvalue = 100,
since = "5.0.0"

Choose a reason for hiding this comment

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

Suggested change
since = "5.0.0"
since = "5.0"

---------------------------------------------------------------------------------------------------
--Issue: https://github.com/smartdevicelink/sdl_core/issues/3309
---------------------------------------------------------------------------------------------------
-- Description: SDL resends the parameter from HMI to mobile app in case app version is less then parameter version,

Choose a reason for hiding this comment

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

Please update the description according to the step

end
return true
end)
m.getMobileSession():ExpectResponse(cid, { success = true, resultCode = "SUCCESS", unpack(vehicleDataRes) })

Choose a reason for hiding this comment

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

Seems 'unpack' function is wrong for vehicleDataRes and return ""

./test_scripts/Defects/4_5/1921_Invalid_PT_after_cutting_unknow_values.lua
./test_scripts/Defects/4_5/1921_Invalid_PT_after_cutting_unknow_values.lua
./test_scripts/Defects/4_5/1921_Invalid_PT_after_cutting_unknow_values.lua
./test_scripts/Defects/4_5/1921_Invalid_PT_after_cutting_unknow_values.lua

Choose a reason for hiding this comment

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

Please remove 1921.txt

---------------------------------------------------------------------------------------------------
--Issue: https://github.com/smartdevicelink/sdl_core/issues/3309
---------------------------------------------------------------------------------------------------
-- Description: SDL cuts off parameter from HMI response,notification if app has less version then parameter version

Choose a reason for hiding this comment

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

Suggested change
-- Description: SDL cuts off parameter from HMI response,notification if app has less version then parameter version
-- Description: SDL cuts off parameter from HMI response/notification if app has less version then parameter version

@GetmanetsIrina
Copy link
Author

@VjKlepikov, please find updates in 57ddca8

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants