How to write unit test for the helper in Meteor Mocha [ Closed ] -


how test following checkuser helper 2 parameters currentuser.username , username using mocha (a javascript test framework)

<div class="col-sm-1">       {{#if checkuser currentuser.username username }}         <button class="btn btn-small btn-danger my-delete-btn pull-right"><span class="glyphicons glyphicon glyphicon-trash"></span></button>       {{/if}} </div> 

welcome so. before ask (way general) question on how solve problem, should first research , write code. if stuck in specific part of coding (like unexpected error thrown , can't traced back) may ask question.

also read when, when not , how ask question on so:

https://stackoverflow.com/help/on-topic

https://stackoverflow.com/help/dont-ask

https://stackoverflow.com/help/mcve

regarding question, may read "how write simple blaze unit test" part of meteor test guide.


Comments

Popular posts from this blog

python - How to insert QWidgets in the middle of a Layout? -

python - serve multiple gunicorn django instances under nginx ubuntu -

module - Prestashop displayPaymentReturn hook url -