deepweeb / B-B-W

0 stars 1 forks source link

added trustvaluecontroller tests and changed trustvalue type to double #144

Closed tjappo closed 7 years ago

tjappo commented 7 years ago

130

Introduction

The current trust value implementation is pretty simple. So it is changed to a way now that the trust value is updated in a decreasing ascending way. Next to that, the trust value type has been changed to a double. All functions, which influence the trust value have been extracted to a new controller: TrustController

Purpose

This way, the trust value will be calculated more accurately and the trust value will reach the upper limit slower. And because the TrustController has been extracted, the code has increased in readability and maintainability.

Future Applicability

Use the TrustController to update the trust values. The enums 'FAILED_TRANSACTION', 'SUCCESFUL_TRANSACTION' and 'VERIFIED_IBAN' have to be removed later, after the refactor

PR Reflection

nzarin commented 7 years ago

Also something for in the 'future'. We might wanna take a look at PageRank (google's algorithm. It is also used for tribler). For now this will work.

coveralls commented 7 years ago

Coverage Status

Coverage increased (+3.7%) to 46.941% when pulling aa631b66bbb38124afa22f0be11a89fa209b4f25 on feature/trustValueOptimization into 4088fcf8097f5df8dc488169146e97be3508bef8 on develop.

tjappo commented 7 years ago

Like the other pull request, 3/4 travis builds run and passed. The other timed out, because the android emulator did not run. I have already run the job again several times, but it did timed out again. The code has no dependencies on the newer sdk, so it is a problem of travis.