Skip to content
This repository was archived by the owner on Aug 2, 2022. It is now read-only.

eosiolib Unit/Regression Tests #424

Merged
merged 55 commits into from
Feb 21, 2019
Merged

eosiolib Unit/Regression Tests #424

merged 55 commits into from
Feb 21, 2019

Conversation

johndebord
Copy link
Contributor

In correspondence with issue #376 unit/regression tests have been implemented for the following files:

  • asset.hpp
  • binary_extension.hpp
  • crypto.hpp
  • datastream.hpp
  • fixed_bytes.hpp
  • name.hpp
  • serialize.hpp
  • symbol.hpp
  • system.hpp
  • time.hpp
  • varint.hpp

This will ensure that the integrity of the data structures and their respective methods in directory eosio.cdt/libraries/eosiolib/ will remain steadfast and consistent throughout any change that might happen to the library in the future.

To run the tests simply enter the build directory (where my generated build directory is eosio.cdt/build/) and run the ctest command.

For example:
~/eosio.cdt/build$ ctest

Copy link
Contributor

@larryk85 larryk85 left a comment

Choose a reason for hiding this comment

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

asset_tests.cpp has warnings about unused comparisons. at lines 326, 519, 524 and 529. These are not doing anything, please change these to CHECK_EQUAL. Also the CHECK_PRINTs at line 424-436 are not correct and the check is failing. Also, where you are checking the string or print for a negative asset, you are using "--". This is a bug, please look at PR #422 and copy his fix over and fix these tests. You will not be able to simply merge his PR as it will overwrite too many things.

Copy link
Contributor Author

@johndebord johndebord left a comment

Choose a reason for hiding this comment

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

Looks good.

@larryk85 larryk85 changed the base branch from develop to release/1.6.x February 21, 2019 22:31
@larryk85 larryk85 merged commit 6517123 into release/1.6.x Feb 21, 2019
@larryk85 larryk85 deleted the cdt-tests branch February 21, 2019 22:32
rise-worlds pushed a commit to potato-coin/eosio.cdt that referenced this pull request Jul 14, 2020
`eosiolib` Unit/Regression Tests
Pipeline is shot, so merging in without full tests.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants