edemo / PDEngine

voting engine using ADA authentication and condorcet method
Other
2 stars 12 forks source link

CastVote.getAssurances() #242

Open magwas opened 5 years ago

magwas commented 5 years ago

Behaviour: Supporting functionality/CastVote;The assurances of the voter can be obtained from a cast vote if canupdateis true

@tested_feature("Supporting functionality")

@tested_operation("CastVote")

@tested_behaviour("The assurances of the voter can be obtained from a cast vote if canupdateis true")

by List getAssurances() The CastVote actually stores the proxy ID for the voter, and consults the voter's User entity

Deviation in model

valentinbujdoso commented 5 years ago

So I have to add List getAssurances() function to CastVote which gives back the assurances of the voter? :O

magwas commented 5 years ago

No, you don't have to give it back. You have to store it with the vote cast. But only if canUpdate is true.

valentinbujdoso commented 5 years ago

Thx. It waits for the merge of #60

valentinbujdoso commented 5 years ago

I am not clearly understand what to do whit this ticket. I have to store the assurances in the CastVote class. So I will add it in the Vote.addCastVote function. But how do I get the users assurances (which I would like to store?

magwas commented 5 years ago

From the User instance, which can be found with the proxy id from ws context. And as this is not yet implemented, you have to use mocks.

valentinbujdoso commented 5 years ago

grab