RGB-WG / rgb-core

RGB Core Library: consensus validation for private & scalable client-validated smart contracts on Bitcoin & Lightning
https://spec.rgb.tech
Apache License 2.0
207 stars 52 forks source link

Make state and operation type system strong #188

Closed dr-orlovsky closed 11 months ago

dr-orlovsky commented 11 months ago

This should prevent issues like https://github.com/RGB-WG/rgb-schemata/blob/943c65d2d408682d75dcd5e651c60ef35d97cc41/src/nia.rs#L40 from happening again.

codecov[bot] commented 11 months ago

Codecov Report

Merging #188 (282d5a9) into master (3932816) will increase coverage by 0.0%. The diff coverage is 13.3%.

:exclamation: Current head 282d5a9 differs from pull request most recent head db12cd9. Consider uploading reports for the commit db12cd9 to get more accurate results

@@          Coverage Diff           @@
##           master    #188   +/-   ##
======================================
  Coverage    16.0%   16.0%           
======================================
  Files          31      31           
  Lines        3398    3436   +38     
======================================
+ Hits          544     551    +7     
- Misses       2854    2885   +31     
Flag Coverage Δ
rust 16.0% <13.3%> (+<0.1%) :arrow_up:

Flags with carried forward coverage won't be shown. Click here to find out more.

Files Coverage Δ
src/contract/operations.rs 24.6% <ø> (ø)
src/stl.rs 100.0% <ø> (ø)
src/validation/status.rs 0.0% <ø> (ø)
src/contract/contract.rs 0.3% <0.0%> (ø)
src/contract/fungible.rs 71.2% <75.0%> (ø)
src/validation/model.rs 0.0% <0.0%> (ø)
src/validation/schema.rs 0.0% <0.0%> (ø)
src/validation/validator.rs 0.0% <0.0%> (ø)
src/schema/operations.rs 20.4% <44.4%> (+6.1%) :arrow_up:
src/schema/schema.rs 59.7% <27.3%> (-6.4%) :arrow_down:
... and 2 more

:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more

dr-orlovsky commented 11 months ago

@zoedberg I was splitting the same history into two PRs thus missed this thing. Now should be fine