⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 checkargumentstest.java

📁 This project developed in java leads us to realize a flight reservation system in order to emulate d
💻 JAVA
字号:
/* * checkArgumentsTest.java * JUnit based test * * Created on 8 novembre 2004, 11:22 */package test;import reservation.system.functions.Functions;import java.util.Vector;import java.util.ListIterator;import java.util.LinkedList;import java.util.Collection;import java.util.HashSet;import java.util.Set;import junit.framework.*;/** * * @author mathieu */public class checkArgumentsTest extends TestCase {        public checkArgumentsTest (java.lang.String testName) {        super (testName);    }        public static Test suite () {        TestSuite suite = new TestSuite (checkArgumentsTest.class);        return suite;    }        /**     * Test of validityArgument method, of class FlightSystem.checkArguments.     */    public void testArgumentisValid () {        System.out.println ("testArgumentIsValid");        String errorString = "Error";        try {            Functions.ArgumentIsValid (new String[]{"Adam","Caroline"},0,0);            fail ("Illegal number of argument");        } catch (Exception e) {System.out.println (errorString + " OK :" + e.getMessage ());}                try {            Functions.ArgumentIsValid (new String[]{null},0,0);            fail ("Illegal number of argument and argument null");        } catch (Exception e) {System.out.println (errorString + " OK :" + e.getMessage ());}                try {            Functions.ArgumentIsValid (new String[]{"Adam","Caroline"},2,0);            fail ("The max must be superior to the min.");        } catch (Exception e) {System.out.println (errorString + " OK :" + e.getMessage ());}    }}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -