[WIP] Aggsig Transactions (#530)
* First steps converting transaction workflow to be aggsig-enable * integrating updated version of aggsig, which gives greater control over the contents of e * added wallet transaction test to testing framework to enable testing the whole thing, completed interaction as far as inital response from recipient * more aggsig work, final signature is produced now * Construction of aggsig transaction now working to the point of the signature being built * aggsig transactions working end-to-end in the nominal case * refactor aggsig verify from commit and fix some tests * more cleanup and test fixing * cleaning up automated tests * test+formatting fix
This commit is contained in:
+9
-3
@@ -737,7 +737,7 @@ mod tests {
|
||||
// a valid transaction.
|
||||
let valid_transaction = test_transaction(vec![5, 6], vec![9]);
|
||||
|
||||
match write_pool.add_to_memory_pool(test_source(), valid_transaction) {
|
||||
match write_pool.add_to_memory_pool(test_source(), valid_transaction.clone()) {
|
||||
Ok(_) => {}
|
||||
Err(x) => panic!("Unexpected error while adding a valid transaction: {:?}", x),
|
||||
};
|
||||
@@ -764,9 +764,15 @@ mod tests {
|
||||
}
|
||||
};
|
||||
|
||||
let already_in_pool = test_transaction(vec![5, 6], vec![9]);
|
||||
// Note, this used to work as expected, but after aggsig implementation
|
||||
// creating another transaction with the same inputs/outputs doesn't create
|
||||
// the same hash ID due to the random nonces in an aggsig. This
|
||||
// will instead throw a (correct as well) Already spent error. An AlreadyInPool
|
||||
// error can only come up in the case of the exact same transaction being
|
||||
// added
|
||||
//let already_in_pool = test_transaction(vec![5, 6], vec![9]);
|
||||
|
||||
match write_pool.add_to_memory_pool(test_source(), already_in_pool) {
|
||||
match write_pool.add_to_memory_pool(test_source(), valid_transaction) {
|
||||
Ok(_) => panic!("Expected error when adding already in pool, got Ok"),
|
||||
Err(x) => {
|
||||
match x {
|
||||
|
||||
Reference in New Issue
Block a user