Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

What is the best choice of test unit library for SAGE

Now I'm using import unittest. But I'm not sure that it is the best choice in SAGE context.

Something like this

import unittest

class Test(unittest.TestCase):
    def test_CheckLocalTestForI123(self):
      group = gap.GenerateG(2,5,3)
      generators = gap.GeneratorsOfGroup(group);

      subgroups = map(lambda gen: gap.Group(gen), generators);
      subgroups.reverse()

      self.assertNotEqual(CheckLocalTestForI123(group, subgroups, 1621, 1947, 1521), -1)

What are you using and why?

What is the best choice of test unit library for SAGE

Now I'm using

import unittestunittest
. 

But I'm not sure that it is the best choice in SAGE context.

Something like this

import unittest

class Test(unittest.TestCase):
    def test_CheckLocalTestForI123(self):
      group = gap.GenerateG(2,5,3)
      generators = gap.GeneratorsOfGroup(group);

      subgroups = map(lambda gen: gap.Group(gen), generators);
      subgroups.reverse()

      self.assertNotEqual(CheckLocalTestForI123(group, subgroups, 1621, 1947, 1521), -1)

What are you using and why?