Skip to content

Instantly share code, notes, and snippets.

@PreyeaRegmi
Created August 30, 2021 15:06
Show Gist options
  • Save PreyeaRegmi/3b6f13f7ed47531d5fc6eff562ceae0c to your computer and use it in GitHub Desktop.
Save PreyeaRegmi/3b6f13f7ed47531d5fc6eff562ceae0c to your computer and use it in GitHub Desktop.
void main()
{
test("Amount cannot be null",()
{
EMICalculator emiCalculator=EMICalculator(1,2,3);
//Performing assertion
expect(emiCalculator.amount,isNot(null), reason:"Amount cannot be null");
});
test("Rate cannot be null",()
{
EMICalculator emiCalculator=EMICalculator(1,2,3);
//Performing assertion
expect(emiCalculator.rate,isNot(null),reason:"Rate cannot be null");
});
test("Rate cannot be null",()
{
EMICalculator emiCalculator=EMICalculator(1,2,3);
//Performing assertion
expect(emiCalculator.time,isNot(null),reason:"Time cannot be null");
});
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment