PageRenderTime 18ms CodeModel.GetById 12ms app.highlight 2ms RepoModel.GetById 1ms app.codeStats 0ms

/test/language/unclassified/test_system_tools.e

http://github.com/tybor/Liberty
Specman e | 140 lines | 112 code | 7 blank | 21 comment | 1 complexity | d5c2da673e88c3bccd6e83085eb57f08 MD5 | raw file
  1-- This file is part of SmartEiffel The GNU Eiffel Compiler Tools and Libraries.
  2-- See the Copyright notice at the end of this file.
  3--
  4class TEST_SYSTEM_TOOLS
  5
  6inherit
  7	SYSTEM_TOOLS
  8
  9creation {ANY}
 10	runit
 11
 12feature {ANY}
 13	runit is
 14		do
 15			c_compiler := gcc
 16			system_name := unix_system
 17			check_it(1, "f1.o")
 18			check_it(2, "f1.o f2.o")
 19			check_it(3, "f[1-3].o")
 20			check_it(4, "f[1-4].o")
 21			check_it(5, "f[1-5].o")
 22			check_it(6, "f[1-6].o")
 23			check_it(7, "f[1-7].o")
 24			check_it(8, "f[1-8].o")
 25			check_it(9, "f[1-9].o")
 26			check_it(10, "f[1-9].o f10.o")
 27			check_it(11, "f[1-9].o f1[0-1].o")
 28			check_it(12, "f[1-9].o f1[0-2].o")
 29			check_it(13, "f[1-9].o f1[0-3].o")
 30			check_it(14, "f[1-9].o f1[0-4].o")
 31			check_it(15, "f[1-9].o f1[0-5].o")
 32			check_it(16, "f[1-9].o f1[0-6].o")
 33			check_it(17, "f[1-9].o f1[0-7].o")
 34			check_it(18, "f[1-9].o f1[0-8].o")
 35			check_it(19, "f[1-9].o f1[0-9].o")
 36			check_it(20, "f[1-9].o f1[0-9].o f20.o")
 37			check_it(21, "f[1-9].o f1[0-9].o f2[0-1].o")
 38			check_it(22, "f[1-9].o f1[0-9].o f2[0-2].o")
 39			check_it(23, "f[1-9].o f1[0-9].o f2[0-3].o")
 40			check_it(24, "f[1-9].o f1[0-9].o f2[0-4].o")
 41			check_it(25, "f[1-9].o f1[0-9].o f2[0-5].o")
 42			check_it(26, "f[1-9].o f1[0-9].o f2[0-6].o")
 43			check_it(27, "f[1-9].o f1[0-9].o f2[0-7].o")
 44			check_it(28, "f[1-9].o f1[0-9].o f2[0-8].o")
 45			check_it(29, "f[1-9].o f[1-2][0-9].o")
 46			check_it(30, "f[1-9].o f[1-2][0-9].o f30.o")
 47			check_it(31, "f[1-9].o f[1-2][0-9].o f3[0-1].o")
 48			check_it(32, "f[1-9].o f[1-2][0-9].o f3[0-2].o")
 49			check_it(33, "f[1-9].o f[1-2][0-9].o f3[0-3].o")
 50			check_it(34, "f[1-9].o f[1-2][0-9].o f3[0-4].o")
 51			check_it(35, "f[1-9].o f[1-2][0-9].o f3[0-5].o")
 52			check_it(36, "f[1-9].o f[1-2][0-9].o f3[0-6].o")
 53			check_it(37, "f[1-9].o f[1-2][0-9].o f3[0-7].o")
 54			check_it(38, "f[1-9].o f[1-2][0-9].o f3[0-8].o")
 55			check_it(39, "f[1-9].o f[1-3][0-9].o")
 56			check_it(40, "f[1-9].o f[1-3][0-9].o f40.o")
 57			check_it(41, "f[1-9].o f[1-3][0-9].o f4[0-1].o")
 58			check_it(42, "f[1-9].o f[1-3][0-9].o f4[0-2].o")
 59			check_it(43, "f[1-9].o f[1-3][0-9].o f4[0-3].o")
 60			check_it(44, "f[1-9].o f[1-3][0-9].o f4[0-4].o")
 61			check_it(45, "f[1-9].o f[1-3][0-9].o f4[0-5].o")
 62			check_it(46, "f[1-9].o f[1-3][0-9].o f4[0-6].o")
 63			check_it(47, "f[1-9].o f[1-3][0-9].o f4[0-7].o")
 64			check_it(48, "f[1-9].o f[1-3][0-9].o f4[0-8].o")
 65			check_it(49, "f[1-9].o f[1-4][0-9].o")
 66			check_it(50, "f[1-9].o f[1-4][0-9].o f50.o")
 67			check_it(51, "f[1-9].o f[1-4][0-9].o f5[0-1].o")
 68			check_it(52, "f[1-9].o f[1-4][0-9].o f5[0-2].o")
 69			check_it(53, "f[1-9].o f[1-4][0-9].o f5[0-3].o")
 70			check_it(54, "f[1-9].o f[1-4][0-9].o f5[0-4].o")
 71			check_it(55, "f[1-9].o f[1-4][0-9].o f5[0-5].o")
 72			check_it(56, "f[1-9].o f[1-4][0-9].o f5[0-6].o")
 73			check_it(57, "f[1-9].o f[1-4][0-9].o f5[0-7].o")
 74			check_it(58, "f[1-9].o f[1-4][0-9].o f5[0-8].o")
 75			check_it(59, "f[1-9].o f[1-5][0-9].o")
 76			check_it(60, "f[1-9].o f[1-5][0-9].o f60.o")
 77			check_it(61, "f[1-9].o f[1-5][0-9].o f6[0-1].o")
 78			check_it(62, "f[1-9].o f[1-5][0-9].o f6[0-2].o")
 79			check_it(63, "f[1-9].o f[1-5][0-9].o f6[0-3].o")
 80			check_it(64, "f[1-9].o f[1-5][0-9].o f6[0-4].o")
 81			check_it(65, "f[1-9].o f[1-5][0-9].o f6[0-5].o")
 82			check_it(66, "f[1-9].o f[1-5][0-9].o f6[0-6].o")
 83			check_it(67, "f[1-9].o f[1-5][0-9].o f6[0-7].o")
 84			check_it(68, "f[1-9].o f[1-5][0-9].o f6[0-8].o")
 85			check_it(69, "f[1-9].o f[1-6][0-9].o")
 86			check_it(70, "f[1-9].o f[1-6][0-9].o f70.o")
 87			check_it(71, "f[1-9].o f[1-6][0-9].o f7[0-1].o")
 88			check_it(72, "f[1-9].o f[1-6][0-9].o f7[0-2].o")
 89			check_it(73, "f[1-9].o f[1-6][0-9].o f7[0-3].o")
 90			check_it(74, "f[1-9].o f[1-6][0-9].o f7[0-4].o")
 91			check_it(75, "f[1-9].o f[1-6][0-9].o f7[0-5].o")
 92			check_it(76, "f[1-9].o f[1-6][0-9].o f7[0-6].o")
 93			check_it(77, "f[1-9].o f[1-6][0-9].o f7[0-7].o")
 94			check_it(78, "f[1-9].o f[1-6][0-9].o f7[0-8].o")
 95			check_it(79, "f[1-9].o f[1-7][0-9].o")
 96		ensure
 97			Current = old Current
 98		end
 99
100	check_it (n: INTEGER; match: STRING) is
101		local
102			cmd: STRING
103		do
104			create cmd.make(4)
105			add_objects(cmd, "f", n)
106			assert(match.is_equal(cmd))
107		end
108
109	assert (b: BOOLEAN) is
110		do
111			cpt := cpt + 1
112			if not b then
113				sedb_breakpoint
114				std_output.put_string("TEST_SYSTEM_TOOLS: ERROR Test # ")
115				std_output.put_integer(cpt)
116				std_output.put_string("%N")
117			end
118		end
119
120	cpt: INTEGER
121
122end -- class TEST_SYSTEM_TOOLS
123--
124-- ------------------------------------------------------------------------------------------------------------------------------
125-- Copyright notice below. Please read.
126--
127-- SmartEiffel is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License,
128-- as published by the Free Software Foundation; either version 2, or (at your option) any later version.
129-- SmartEiffel is distributed in the hope that it will be useful but WITHOUT ANY WARRANTY; without even the implied warranty
130-- of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have
131-- received a copy of the GNU General Public License along with SmartEiffel; see the file COPYING. If not, write to the Free
132-- Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
133--
134-- Copyright(C) 1994-2002: INRIA - LORIA (INRIA Lorraine) - ESIAL U.H.P.       - University of Nancy 1 - FRANCE
135-- Copyright(C) 2003-2006: INRIA - LORIA (INRIA Lorraine) - I.U.T. Charlemagne - University of Nancy 2 - FRANCE
136--
137-- Authors: Dominique COLNET, Philippe RIBET, Cyril ADRIAN, Vincent CROIZIER, Frederic MERIZEN
138--
139-- http://SmartEiffel.loria.fr - SmartEiffel@loria.fr
140-- ------------------------------------------------------------------------------------------------------------------------------