Skip to content

Instantly share code, notes, and snippets.

@krsmanian1972
Created September 29, 2019 14:33
Show Gist options
  • Save krsmanian1972/64699016325e6e6cd64e3e3f32cebf4b to your computer and use it in GitHub Desktop.
Save krsmanian1972/64699016325e6e6cd64e3e3f32cebf4b to your computer and use it in GitHub Desktop.
CoinTenderShould
package com.krscode;
import static org.junit.Assert.assertEquals;
import org.junit.Test;
public class CoinTenderShould {
@Test
public void dispenseCoins() {
assertEquals("P", CoinTender.dispense(1));
assertEquals("PPPP", CoinTender.dispense(4));
assertEquals("NPP", CoinTender.dispense(7));
assertEquals("DNPP", CoinTender.dispense(17));
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment