Commit Graph

113 Commits

Author SHA1 Message Date
Olaoluwa Osuntokun
cdb7436e34
htlcswitch: update tests to account for new HTLC expiry observence 2017-08-02 21:11:40 -07:00
Olaoluwa Osuntokun
b6057abe93
hltcswitch: increase timeout for bi-di payment test due to travis slowness
This commit temporary increases the timeout for the
TestChannelLinkBidirectionalOneHopPayments test in order to account for
the slowness of the travis instances that our tests are run on.
2017-08-01 12:53:17 -07:00
Olaoluwa Osuntokun
747e0f57d1
multi: fix linter errors 2017-07-30 18:22:45 -07:00
Olaoluwa Osuntokun
402112e6ee
htlcswitch: update tests utilities to be aware of new commitment design 2017-07-30 17:51:20 -07:00
Andrey Samokhvalov
2d378b3280 htlcswitch+router: add onion error obfuscation
Within the network, it's important that when an HTLC forwarding failure
occurs, the recipient is notified in a timely manner in order to ensure
that errors are graceful and not unknown. For that reason with
accordance to BOLT №4 onion failure obfuscation have been added.
2017-07-14 19:08:04 -07:00
Johan T. Halseth
f4db249cb8 htlcswitch: handle update_fee message received from peer.
This commit makes the channellink update a channel's fee
if an update_fee message is received from the peer.
2017-07-14 16:39:15 -07:00
Andrey Samokhvalov
c13e36617c htlcswitch: return time result from bidirection test 2017-06-26 20:26:27 +03:00
Andrey Samokhvalov
c233b8816e htlcswitch: increase payment timeout in bydirectional unit test
During travis tests the latency of payment might lead to test failure,
for that reason we increase the waiting timeout.
2017-06-25 14:19:56 +01:00
Olaoluwa Osuntokun
e2e21243d2
htlcswitch: make linter happy on go 1.7 2017-06-17 01:10:08 +02:00
Olaoluwa Osuntokun
bb9bc9205a
htlcswitch: run all unit tests in parallel 2017-06-17 00:41:47 +02:00
Olaoluwa Osuntokun
e477241de1
htlcswitch: update test utilities to latest switch/link changes 2017-06-17 00:03:42 +02:00
Andrey Samokhvalov
7595bee27c htlcswitch: add usage of queue in channel link
In this commit usage of the pending packet queue have been added.
This queue will consume the downstream packets if state machine return
the error that we do not have enough capacity for htlc in commitment
transaction. Upon receiving settle/fail payment descriptors - add htlc
have been removed, we release the slot, and process pending add htlc
requests.
2017-05-31 11:06:08 -07:00
Andrey Samokhvalov
882aec704d htlcswitch: add channel link tests
Step #5 in making htlcManager (aka channelLink) testable:
Combine all that have been done so far and add test framework for channel
links which allow unit test:

* message ordering
* detect redundant messages
* single hop payment
* multihop payment
* several cancel payment scenarios
2017-05-31 11:06:08 -07:00