home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 5 / Apprentice-Release5.iso / Environments / SmallEiffel 0.3.3 / SmallEiffel 68k / lib_test / test_integer2.e < prev    next >
Encoding:
Text File  |  1996-06-13  |  630 b   |  35 lines  |  [TEXT/EDIT]

  1. -- Part of SmallEiffel -- Read DISCLAIMER file -- Copyright (C) 
  2. -- Dominique COLNET and Suzanne COLLIN -- colnet@loria.fr
  3. --
  4. class TEST_INTEGER2
  5.  
  6. creation {ANY}
  7.    make
  8.    
  9. feature {ANY}
  10.    
  11.    make is
  12.       local
  13.      d: DOUBLE;
  14.       do
  15.      d := 2/3;
  16.      is_true((0.6665).to_double < d);
  17.      is_true(d < 0.6667);
  18.       end;
  19.    
  20.    is_true(b: BOOLEAN) is
  21.       do
  22.      cpt := cpt + 1;
  23.      if not b then
  24.         std_output.put_string("TEST_INTEGER2: ERROR Test # ");
  25.         std_output.put_integer(cpt);
  26.         std_output.put_string("%N");
  27.      else
  28.         -- std_output.put_string("Yes%N");
  29.      end;
  30.       end;
  31.    
  32.    cpt: INTEGER;
  33.    
  34. end -- TEST_INTEGER2
  35.