Skip to content

Kvstore tests api change to run on K64F only #9244

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
merged 2 commits into from
Jan 10, 2019

Conversation

theamirocohen
Copy link
Contributor

@theamirocohen theamirocohen commented Jan 3, 2019

Change KVStore API tests to run only on K64F, these tests check the KVStore functionality without actually testing the board's storage, Thus they should produce the same results for each device they run on.
We don't see a point loading the CI with these tests if they all produce the same result regardless of the board.
The one test that does run on the actual board's storage is static_tests, which wasn't changed.
K64F was selected for no special technical reason but only because of it being available and convenient to use.

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

@ciarmcom ciarmcom requested review from a team January 3, 2019 16:00
@ciarmcom
Copy link
Member

ciarmcom commented Jan 3, 2019

@theamirocohen, thank you for your changes.
@ARMmbed/mbed-os-storage @ARMmbed/mbed-os-maintainers please review.

@0xc0170
Copy link
Contributor

0xc0170 commented Jan 3, 2019

Change KVStore API tests to run only on K64F, these tests only check functionality.

Why only on one target ?

@davidsaada
Copy link
Contributor

davidsaada commented Jan 3, 2019

Why only on one target ?

The modified tests check the functionality of the various KVStore APIs. Most of them run in memory (over the Heap block device). Thus they should produce the same results for each device they run on (providing it has enough RAM). In other words, these tests check the KVStore functionality without actually testing the board's storage. The one test that does run on the actual board's storage is static_tests, which wasn't changed in this PR. We don't see a point loading the CI with these tests if they all produce the same result regardless of the board.

@dannybenor
Copy link

The real and wide test for different boards is the test for the static API. Until now, this test was also not executed in many targets because the default configuration was for external memory, and not many boards have the right components in targets.json.
With the new configuration, we will get better coverage, because the default will be selected according to the defined components in targets.json. This is one of the breaking changes.

@0xc0170
Copy link
Contributor

0xc0170 commented Jan 4, 2019

I would like to have @ARMmbed/mbed-os-test review.

This feels like there should be unit tests rather? Testing only on one target does not feel right (why only one and why that one will be questions we get)

Copy link
Contributor

@OPpuolitaival OPpuolitaival left a comment

Choose a reason for hiding this comment

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

Not optimal solution but good to run even with one board. These tests seems to need real device and therefore cannot be replaced with unit testing.

@jeromecoutant
Copy link
Collaborator

Target Toolchain TestSuite TestCase mbed-os-5.11.0
DISCO_F407VG ARM features-storage-tests-kvstore-general_tests_phase_1 features-storage-tests-kvstore-general_tests_phase_1 OK
DISCO_F407VG ARM features-storage-tests-kvstore-general_tests_phase_2 features-storage-tests-kvstore-general_tests_phase_2 OK
DISCO_F429ZI ARM features-storage-tests-kvstore-general_tests_phase_1 features-storage-tests-kvstore-general_tests_phase_1 OK
DISCO_F429ZI ARM features-storage-tests-kvstore-general_tests_phase_2 features-storage-tests-kvstore-general_tests_phase_2 OK
DISCO_F746NG ARM features-storage-tests-kvstore-general_tests_phase_1 features-storage-tests-kvstore-general_tests_phase_1 OK
DISCO_F746NG ARM features-storage-tests-kvstore-general_tests_phase_2 features-storage-tests-kvstore-general_tests_phase_2 OK
DISCO_F769NI ARM features-storage-tests-kvstore-general_tests_phase_1 features-storage-tests-kvstore-general_tests_phase_1 OK
DISCO_F769NI ARM features-storage-tests-kvstore-general_tests_phase_2 features-storage-tests-kvstore-general_tests_phase_2 OK
DISCO_L072CZ_LRWAN1 ARM features-storage-tests-kvstore-general_tests_phase_1 features-storage-tests-kvstore-general_tests_phase_1 OK
DISCO_L072CZ_LRWAN1 ARM features-storage-tests-kvstore-general_tests_phase_2 features-storage-tests-kvstore-general_tests_phase_2 OK
NUCLEO_F070RB ARM features-storage-tests-kvstore-general_tests_phase_1 features-storage-tests-kvstore-general_tests_phase_1 OK
NUCLEO_F070RB ARM features-storage-tests-kvstore-general_tests_phase_2 features-storage-tests-kvstore-general_tests_phase_2 OK
NUCLEO_F072RB ARM features-storage-tests-kvstore-general_tests_phase_1 features-storage-tests-kvstore-general_tests_phase_1 OK
NUCLEO_F072RB ARM features-storage-tests-kvstore-general_tests_phase_2 features-storage-tests-kvstore-general_tests_phase_2 OK
NUCLEO_F303RE ARM features-storage-tests-kvstore-general_tests_phase_1 features-storage-tests-kvstore-general_tests_phase_1 OK
NUCLEO_F303RE ARM features-storage-tests-kvstore-general_tests_phase_2 features-storage-tests-kvstore-general_tests_phase_2 OK
NUCLEO_F401RE ARM features-storage-tests-kvstore-general_tests_phase_1 features-storage-tests-kvstore-general_tests_phase_1 OK
NUCLEO_F401RE ARM features-storage-tests-kvstore-general_tests_phase_2 features-storage-tests-kvstore-general_tests_phase_2 OK
NUCLEO_F410RB ARM features-storage-tests-kvstore-general_tests_phase_1 features-storage-tests-kvstore-general_tests_phase_1 OK
NUCLEO_F410RB ARM features-storage-tests-kvstore-general_tests_phase_2 features-storage-tests-kvstore-general_tests_phase_2 OK
NUCLEO_F411RE ARM features-storage-tests-kvstore-general_tests_phase_1 features-storage-tests-kvstore-general_tests_phase_1 OK
NUCLEO_F411RE ARM features-storage-tests-kvstore-general_tests_phase_2 features-storage-tests-kvstore-general_tests_phase_2 OK
NUCLEO_F412ZG ARM features-storage-tests-kvstore-general_tests_phase_1 features-storage-tests-kvstore-general_tests_phase_1 OK
NUCLEO_F412ZG ARM features-storage-tests-kvstore-general_tests_phase_2 features-storage-tests-kvstore-general_tests_phase_2 OK
NUCLEO_F413ZH ARM features-storage-tests-kvstore-general_tests_phase_1 features-storage-tests-kvstore-general_tests_phase_1 OK
NUCLEO_F413ZH ARM features-storage-tests-kvstore-general_tests_phase_2 features-storage-tests-kvstore-general_tests_phase_2 OK
NUCLEO_F429ZI ARM features-storage-tests-kvstore-general_tests_phase_1 features-storage-tests-kvstore-general_tests_phase_1 OK
NUCLEO_F429ZI ARM features-storage-tests-kvstore-general_tests_phase_2 features-storage-tests-kvstore-general_tests_phase_2 OK
NUCLEO_F439ZI ARM features-storage-tests-kvstore-general_tests_phase_1 features-storage-tests-kvstore-general_tests_phase_1 OK
NUCLEO_F439ZI ARM features-storage-tests-kvstore-general_tests_phase_2 features-storage-tests-kvstore-general_tests_phase_2 OK
NUCLEO_F446ZE ARM features-storage-tests-kvstore-general_tests_phase_1 features-storage-tests-kvstore-general_tests_phase_1 OK
NUCLEO_F446ZE ARM features-storage-tests-kvstore-general_tests_phase_2 features-storage-tests-kvstore-general_tests_phase_2 OK
NUCLEO_F746ZG ARM features-storage-tests-kvstore-general_tests_phase_1 features-storage-tests-kvstore-general_tests_phase_1 OK
NUCLEO_F746ZG ARM features-storage-tests-kvstore-general_tests_phase_2 features-storage-tests-kvstore-general_tests_phase_2 OK
NUCLEO_F756ZG ARM features-storage-tests-kvstore-general_tests_phase_1 features-storage-tests-kvstore-general_tests_phase_1 OK
NUCLEO_F756ZG ARM features-storage-tests-kvstore-general_tests_phase_2 features-storage-tests-kvstore-general_tests_phase_2 OK
NUCLEO_L432KC ARM features-storage-tests-kvstore-general_tests_phase_1 features-storage-tests-kvstore-general_tests_phase_1 OK
NUCLEO_L432KC ARM features-storage-tests-kvstore-general_tests_phase_2 features-storage-tests-kvstore-general_tests_phase_2 OK
NUCLEO_L433RC_P ARM features-storage-tests-kvstore-general_tests_phase_1 features-storage-tests-kvstore-general_tests_phase_1 OK
NUCLEO_L433RC_P ARM features-storage-tests-kvstore-general_tests_phase_2 features-storage-tests-kvstore-general_tests_phase_2 OK
NUCLEO_L486RG ARM features-storage-tests-kvstore-general_tests_phase_1 features-storage-tests-kvstore-general_tests_phase_1 OK
NUCLEO_L486RG ARM features-storage-tests-kvstore-general_tests_phase_2 features-storage-tests-kvstore-general_tests_phase_2 OK
NUCLEO_L496ZG ARM features-storage-tests-kvstore-general_tests_phase_1 features-storage-tests-kvstore-general_tests_phase_1 OK
NUCLEO_L496ZG ARM features-storage-tests-kvstore-general_tests_phase_2 features-storage-tests-kvstore-general_tests_phase_2 OK
NUCLEO_L4R5ZI ARM features-storage-tests-kvstore-general_tests_phase_1 features-storage-tests-kvstore-general_tests_phase_1 OK
NUCLEO_L4R5ZI ARM features-storage-tests-kvstore-general_tests_phase_2 features-storage-tests-kvstore-general_tests_phase_2 OK
DISCO_L496AG ARM features-storage-tests-kvstore-general_tests_phase_1 features-storage-tests-kvstore-general_tests_phase_1 OK
DISCO_L496AG ARM features-storage-tests-kvstore-general_tests_phase_2 features-storage-tests-kvstore-general_tests_phase_2 OK

@0xc0170
Copy link
Contributor

0xc0170 commented Jan 7, 2019

@theamirocohen as already asked, can you add to the commit message a reason for limiting to just one target and why it was chosen that specific target?

Copy link
Contributor

@0xc0170 0xc0170 left a comment

Choose a reason for hiding this comment

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

As my comment above ^^

@0xc0170
Copy link
Contributor

0xc0170 commented Jan 8, 2019

The only blocking thing here is the request above and @ARMmbed/mbed-os-storage team approval

Change KVStore API tests to run only on K64F, these tests check the KVStore functionality without actually testing the board's storage,
Thus they should produce the same results for each device they run on.
K64F was selected for no special technical reason but only because of it being available and convenient to use.
@theamirocohen
Copy link
Contributor Author

@theamirocohen as already asked, can you add to the commit message a reason for limiting to just one target and why it was chosen that specific target?

The commits were merged and the commit message was changed

@jeromecoutant
Copy link
Collaborator

What about removing features/storage/kvstore/mbed_lib.json file,
and add the KVSTORE_ENABLED macro only in your unit test environment ?

@davidsaada
Copy link
Contributor

What about removing features/storage/kvstore/mbed_lib.json file,
and add the KVSTORE_ENABLED macro only in your unit test environment ?

Good idea. @theamirocohen Can you take care of it? It's indeed not required now as the tests only run on K64F.

In addition, use the NOT_SUPPORTED directive to skip the tests.
@davidsaada
Copy link
Contributor

Removed KVStore's mbed_lib.json file.

Copy link
Collaborator

@jeromecoutant jeromecoutant left a comment

Choose a reason for hiding this comment

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

Then patch in test files are not needed any more ...?

@davidsaada
Copy link
Contributor

Then patch in test files are not needed any more ...?

Which patches?

@0xc0170
Copy link
Contributor

0xc0170 commented Jan 9, 2019

CI started

@cmonr
Copy link
Contributor

cmonr commented Jan 9, 2019

Relaunching Travis CI.

Not sure why, but results didn't propigate...

@mbed-ci
Copy link

mbed-ci commented Jan 10, 2019

Test run: FAILED

Summary: 1 of 11 test jobs failed
Build number : 1
Build artifacts

Failed test jobs:

  • jenkins-ci/mbed-os-ci_greentea-test

@offirko
Copy link
Contributor

offirko commented Jan 10, 2019

@ARMmbed/mbed-os-maintainers - Seems like it failed again to propagate:
(can you examine and rerun?)
[greentea-test] Starting building: mbed-os-ci_greentea-test #751
[Pipeline] [greentea-test] echo
[greentea-test] Exited https://mbed-os.mbedcloudtesting.com/job/mbed-os-ci_greentea-test with result hudson.AbortException: mbed-os-ci_greentea-test #751 completed with status FAILURE (propagate: false to ignore)

@0xc0170
Copy link
Contributor

0xc0170 commented Jan 10, 2019

Test restarted

@0xc0170
Copy link
Contributor

0xc0170 commented Jan 10, 2019

I restarted also travis (it's not yet appearing to be pending here)

@0xc0170
Copy link
Contributor

0xc0170 commented Jan 10, 2019

Reopening this PR to get travis reenabled (does not report back anything but it's green)

@0xc0170 0xc0170 closed this Jan 10, 2019
@0xc0170 0xc0170 removed the needs: CI label Jan 10, 2019
@0xc0170 0xc0170 reopened this Jan 10, 2019
@0xc0170
Copy link
Contributor

0xc0170 commented Jan 10, 2019

Travis green 💯

@0xc0170
Copy link
Contributor

0xc0170 commented Jan 10, 2019

All green

@0xc0170 0xc0170 merged commit d20b591 into ARMmbed:master Jan 10, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

10 participants