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

PSA: automatic mocking of PSA targets in test builds #9953

Merged
merged 1 commit into from Mar 7, 2019

Conversation

Projects
None yet
@orenc17
Copy link
Contributor

commented Mar 6, 2019

Description

When creating test_spec.json for PSA targets builds, removing the _PSA and _NS suffixes from the platform field will allow to run the tests without the need for mbedls mock

Pull request type

[X] Fix
[ ] Refactor
[ ] Target update
[ ] Functionality change
[ ] Docs update
[ ] Test update
[ ] Breaking change

Reviewers

@bridadan

Release Notes

@ciarmcom ciarmcom requested review from bridadan and ARMmbed/mbed-os-maintainers Mar 6, 2019

@ciarmcom

This comment has been minimized.

Copy link
Member

commented Mar 6, 2019

@orenc17, thank you for your changes.
@bridadan @ARMmbed/mbed-os-tools @ARMmbed/mbed-os-maintainers please review.

@0xc0170

This comment has been minimized.

Copy link
Member

commented Mar 6, 2019

When creating test_spec.json for PSA targets builds, removing the _PSA and _NS suffixes from the platform field will allow to run the tests without the need for mbedls mock

Add this to the commit msg - why are we removing these suffixes.

@theotherjimmy
Copy link
Contributor

left a comment

Thanks for keeping this behavior to only affect PSA targets.

@juhhov

This comment has been minimized.

Copy link

commented Mar 6, 2019

Mbedls v1.7.2 adds the _NS ending for LPC55S69. https://github.com/ARMmbed/mbed-os-tools/releases/tag/v0.0.3.

@bridadan
Copy link
Contributor

left a comment

Looks ok. In the future, I'd like to move away from having the target name for PSA targets changing the behavior of the build system. Ideally this is handled by target config. But that's for a later change.

@bridadan

This comment has been minimized.

Copy link
Contributor

commented Mar 6, 2019

@juhhov thanks for the heads up, we'll need to change that target back.

@0xc0170

0xc0170 approved these changes Mar 7, 2019

@0xc0170

This comment has been minimized.

Copy link
Member

commented Mar 7, 2019

I started CI

When creating test_spec.json for PSA targets builds, removing the _PSA and _NS suffixes from the platform field will allow to run the tests without the need for mbedls mock

Reminder, this should be added to the merge commit

@0xc0170 0xc0170 added needs: CI and removed needs: review labels Mar 7, 2019

@0xc0170

This comment has been minimized.

Copy link
Member

commented Mar 7, 2019

CI restared (CI issue in the logs)

@mbed-ci

This comment has been minimized.

Copy link

commented Mar 7, 2019

Test run: SUCCESS

Summary: 13 of 13 test jobs passed
Build number : 2
Build artifacts

@cmonr cmonr merged commit 5c0d226 into ARMmbed:master Mar 7, 2019

28 checks passed

continuous-integration/jenkins/pr-head This commit looks good
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
jenkins-ci/build-ARMC5 Success
Details
jenkins-ci/build-ARMC6 Success
Details
jenkins-ci/build-GCC_ARM Success
Details
jenkins-ci/build-IAR8 Success
Details
jenkins-ci/cloud-client-test Success
Details
jenkins-ci/dynamic-memory-usage RTOS ROM(+0 bytes) RAM(+0 bytes)
Details
jenkins-ci/exporter Success
Details
jenkins-ci/greentea-test Success
Details
jenkins-ci/mbed2-build-ARMC5 Success
Details
jenkins-ci/mbed2-build-ARMC6 Success
Details
jenkins-ci/mbed2-build-GCC_ARM Success
Details
jenkins-ci/mbed2-build-IAR8 Success
Details
jenkins-ci/unittests Success
Details
travis-ci/astyle Local astyle testing has passed
Details
travis-ci/docs Local docs testing has passed
Details
travis-ci/doxy-spellcheck Local doxy-spellcheck testing has passed
Details
travis-ci/events Passed, runtime is 10431 cycles (+502 cycles)
Details
travis-ci/gitattributestest Local gitattributestest testing has passed
Details
travis-ci/include_check Local include_check testing has passed
Details
travis-ci/licence_check Local licence_check testing has passed
Details
travis-ci/littlefs Passed, code size is 8408B (+0.00%)
Details
travis-ci/psa-autogen Local psa-autogen testing has passed
Details
travis-ci/tools-py2.7 Local tools-py2.7 testing has passed
Details
travis-ci/tools-py3.5 Local tools-py3.5 testing has passed
Details
travis-ci/tools-py3.6 Local tools-py3.6 testing has passed
Details
travis-ci/tools-py3.7 Local tools-py3.7 testing has passed
Details

@cmonr cmonr removed the needs: CI label Mar 7, 2019

@orenc17 orenc17 deleted the kfnta:mock_fix branch Mar 7, 2019

@mmahadevan108

This comment has been minimized.

Copy link
Contributor

commented Mar 8, 2019

@bridadan @orenc17 I am unable to run any tests after this change:

mbedgt: detected 1 device
mbedgt: processing target 'LPC55S69' toolchain 'GCC_ARM' compatible platforms... (note: switch set to --parallel 1)
mbedgt: all tests finished!
mbedgt: shuffle seed: 0.6296639662
mbedgt: no platform/target matching tests were found!
mbedgt: no matching platforms were found!

mbedgt: completed in 0.08 sec
mbedgt: exited with code 1
[mbed] ERROR: "mbedgt" returned error.
Code: 1
Path: "C:\mbed-os-example-blinky"
Command: "mbedgt --test-spec .\BUILD\tests\LPC55S69_NS\GCC_ARM\test_spec.json -n mbed-os-tests-mbed_hal-flash*"

@orenc17

This comment has been minimized.

Copy link
Contributor Author

commented Mar 8, 2019

@mmahadevan108 try mbedls -m 0236:LPC55S69 until the next mbed-os-tools release

@mmahadevan108

This comment has been minimized.

Copy link
Contributor

commented Mar 8, 2019

Thank you, that worked

@bridadan

This comment has been minimized.

Copy link
Contributor

commented Mar 8, 2019

Hey @mmahadevan108, sorry for the inconvenience. This update to the tools will remove the need to mock this target: https://github.com/ARMmbed/mbed-os-tools/pull/136/files#diff-cdab2c4e7a8db8813920d9492624ad09R66

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.