93 Commits

Author SHA1 Message Date
Rodolphe Marques
92392b51a7 Initial implementation to decouple assets from transactions.
Most changes done to how we write and read blocks to the database.
Created schema, indexes and queries for mongodb.
Fixed tests.
2017-05-10 16:43:52 +02:00
Scott Sadler
6fbefd5230 Merge remote-tracking branch 'origin/master' into federation-tests 2017-04-24 15:16:48 +02:00
vrde
2bedc9b059
Fix typos 2017-04-12 14:39:15 +02:00
Scott Sadler
a6ba13dc3e Merge remote-tracking branch 'origin/master' into federation-tests 2017-04-11 11:21:02 +02:00
Rodolphe Marques
da29bbc605 added tests for the events 2017-04-07 15:02:49 +02:00
Rodolphe Marques
cb87221bdf Voting pipeline now checks for duplicated transactions in blocks during
validation.
2017-04-04 17:57:44 +02:00
Scott Sadler
d8b84891b6 federation tests 2017-03-21 16:23:56 +01:00
Scott Sadler
03ca4b1fd3 make stepping pipeline queue items mutable 2017-03-17 15:34:17 +01:00
Scott Sadler
58a1a25d43 test for invalid vote in election pipeline 2017-03-13 16:26:41 +01:00
Scott Sadler
dc58466de3 Merge branch 'master' into voting-class-integration 2017-03-13 13:35:03 +01:00
Scott Sadler
d10772e4bf Merge remote-tracking branch 'origin/master' into voting-class-integration 2017-03-08 12:56:58 +01:00
Scott Sadler
ffccf86c91 Merge remote-tracking branch 'origin/master' into voting-class-integration 2017-03-08 12:54:33 +01:00
Scott Sadler
a71dc66e97 extra test for tx_collector and docs fix 2017-03-02 18:48:03 +01:00
Scott Sadler
1d935b9ae6 dedupe tx in block, reject duplicate tx in block 2017-03-02 14:35:20 +01:00
Scott Sadler
c993f954e0 wip 2017-02-27 20:56:01 +01:00
Scott Sadler
89e76ffec2 fix tests, temporarily disabling some tests that need to be re-written 2017-02-23 21:53:12 +01:00
Scott Sadler
fc2b684f32 use is_new_transaction in pipelines 2017-02-22 13:55:29 +01:00
Scott Sadler
37f5298962 pull stepper changes from no-double-inclusion 2017-02-21 13:51:09 +01:00
Scott Sadler
a23a741253 document MultipipesStepper 2017-02-21 13:13:40 +01:00
Scott Sadler
6110693ae8 provide more documentation for MultipipesStepper 2017-02-21 13:04:43 +01:00
Scott Sadler
7469f60d17 more assertions in test 2017-02-15 15:15:20 +01:00
Scott Sadler
955b018be8 add stepping pipeline and fix issue #1191 2017-02-15 14:59:01 +01:00
Rodolphe Marques
c174271ae6 Make sure BlockPipeline.validate_tx handles all exceptions 2017-02-03 13:05:04 +01:00
Rodolphe Marques
595f7dc701 several fixes to mongodb queries 2017-01-09 13:25:27 +01:00
Brett Sun
8fa3245309 Rename any *util.py to *utils.py (#991) 2016-12-22 17:39:39 +01:00
libscott
5190e0a682 Merge pull request #925 from bigchaindb/inputs-outputs
Inputs & Outputs
2016-12-22 13:52:19 +01:00
Scott Sadler
04a78aacec Merge remote-tracking branch 'origin/master' into inputs-outputs 2016-12-22 13:45:02 +01:00
Brett Sun
2882bee48e Small flake8 fixes for tests (#987) 2016-12-22 11:57:13 +01:00
Brett Sun
9319583ab4 Remove Asset and AssetLink (#982)
* Remove asset.validate_asset and move its validation checks to other areas

* Move Asset.get_asset_id to Transaction

* Remove Asset and AssetLink models

* Add test against creating TRANSFER transactions with bad asset
2016-12-22 10:19:21 +01:00
Sylvain Bellemare
44391da94a Add genesis block fixture and marker 2016-12-21 17:45:14 +01:00
Sylvain Bellemare
fa79fe6783 Add session scope test setup for config and db
resolves #966
2016-12-20 20:37:28 +01:00
libscott
7e33f2bd52 Tx ID as Asset ID (#926)
* Allow AssetLinks to be used in place of Assets in the Transaction Model and enforce `Transaction.transfer()` to only take an AssetLink

* Remove AssetLink's inheritance from Asset

* Remove id from the Asset model

* Fix get_txids_by_asset_id query for rethinkdb after removing asset's uuid

Because `CREATE` transactions don't have an asset that contains an id
anymore, one way to find all the transactions related to an asset is to
query the database twice: once for the `CREATE` transaction and another
for the `TRANSFER` transactions.

* Add TODO notice for vote test utils to be fixtures

* Update asset model documentation to reflect usage of transaction id

* Fix outdated asset description in transaction schema
2016-12-20 17:28:15 +01:00
Scott Sadler
ed55b3984e s/fulfillments/inputs/g && s/conditions/outputs/g (code changes) 2016-12-19 12:29:29 +01:00
Sylvain Bellemare
56feefe3f4 Re-work test fixtures - iteration one 2016-12-15 15:54:15 +01:00
Sylvain Bellemare
65dab4f2eb Group std lib imports together (pep 8) 2016-12-15 15:51:09 +01:00
Ryan Henderson
d8256d50f2 remove rethinkdb calls (#953)
* remove rethinkdb calls from db/conftest.py
2016-12-15 14:16:30 +01:00
Rodolphe Marques
976a3e8254 Merge remote-tracking branch 'origin/master' into feat/905/abstract-db-changefeed 2016-12-14 12:43:47 +01:00
Ryan Henderson
f725279a51 remove old tx recovery on block process start (#903) 2016-12-14 12:33:47 +01:00
Rodolphe Marques
530681c905 Re-added the get_changefeed methos in the pipelines.
Fixed tests.
Fixed typos.
2016-12-13 15:11:25 +01:00
Rodolphe Marques
e303e355db Delete outdated pipelines/utils.py
Reorganized and fixed tests.
2016-12-13 11:17:24 +01:00
Rodolphe Marques
134f9e85a0 Updated vote pipeline to use the changefeed abstraction
Fixed tests.
2016-12-13 11:16:37 +01:00
Rodolphe Marques
f09285d32f Fixed some code typos
Changed election pipeline to use the new changefeed abstraction
2016-12-13 11:16:29 +01:00
Rodolphe Marques
8266dfadb0 Fixed typos
Fixed failing test
2016-12-13 11:15:49 +01:00
Sylvain Bellemare
8a68e24e69 Abstract db layer cherrypick docs (#932)
* Add README.md to tests/ to describe test structure and pytest customizations

* Add package-level docstrings to backends

* Add README.md explaining the backend architecture

* Small improvements to docstrings in backend modules

* Restructure the backend automodule docs

* Add more docstrings to backend connections

* Add init to base backend Connection class to document expected interface

* Reword the backend/README.md docs
2016-12-12 18:28:43 +01:00
Brett Sun
345fc27a39 Remove durability from all database-related calls 2016-12-12 16:07:41 +01:00
Brett Sun
ae52e015ce Fix changefeed tests that were mocking the wrong thing 2016-12-12 15:53:56 +01:00
Brett Sun
9a7e695e18 Fix tests still relying on being able to access removed attribute of the Bigchain class 2016-12-12 15:48:48 +01:00
Brett Sun
941b47d1ac Fix misc tests affected by changes related to database abstraction 2016-12-12 15:48:48 +01:00
Scott Sadler
44a43dcf94 make all tests pass after vote schema introduction 2016-12-12 15:15:38 +01:00
Scott Sadler
c43bf10151 add call to vote schema validate in consensus.py 2016-12-12 15:15:38 +01:00