/src/wrappers/common/test/test_natural2.e

http://github.com/tybor/Liberty · Specman e · 39 lines · 16 code · 8 blank · 15 comment · 0 complexity · 84d8d61d8b7fffd774355d2c99ab9711 MD5 · raw file

  1. class TEST_NATURAL2
  2. inherit
  3. EIFFELTEST_TOOLS
  4. create {ANY}
  5. make
  6. feature {ANY}
  7. make
  8. local
  9. n0, n1: NATURAL_8
  10. do
  11. n0.make_from_signed(0)
  12. assert(n0 = n0.zero)
  13. n1.make_from_signed(1)
  14. assert(n1 = n0.one)
  15. end
  16. end -- class TEST_NATURAL2
  17. -- Copyright (C) 2009-2017: , 2013 Paolo Redaelli, 2013 Cyril Adrian
  18. -- This library is free software; you can redistribute it and/or
  19. -- modify it under the terms of the GNU Lesser General Public License
  20. -- as published by the Free Software Foundation; either version 2.1 of
  21. -- the License, or (at your option) any later version.
  22. --
  23. -- This library is distributed in the hope that it will be useful, but
  24. -- WITHOUT ANY WARRANTY; without even the implied warranty of
  25. -- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  26. -- Lesser General Public License for more details.
  27. --
  28. -- You should have received a copy of the GNU Lesser General Public
  29. -- License along with this library; if not, write to the Free Software
  30. -- Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
  31. -- 02110-1301 USA