import static org.junit.Assert.*;

import org.junit.Test;


public class FZTest {

    int z;
    @Test
    public void testJia() {
        FZ fz = new FZ();
        z = fz.jia(3, 1);
        assertEquals(4,z);
    }
    @Test(expected=ArithmeticException.class)
    public void testchu() {
        double b;
        FZ fz = new FZ();
        b = fz.Chu(3, 0);
        
    }
    @Test
    public void testjian() {
        
        FZ fz = new FZ();
        z = fz.jian(3, 0);
        assertEquals(3,z);
        
    }
    @Test
    public void testCheng() {
        
        FZ fz = new FZ();
        z = fz.Cheng(3, 0);
        assertEquals(0,z);
        
    }


}
View Code

相关文章:

  • 2022-02-21
  • 2022-02-12
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-01-23
  • 2021-09-11
  • 2021-11-12
猜你喜欢
  • 2021-11-11
  • 2021-12-02
  • 2022-01-11
  • 2022-12-23
  • 2021-11-19
  • 2021-11-13
相关资源
相似解决方案