Пример #1
0
class TestDiagramEditor(TestImageGeneratorPluginMixin, tests.TestCase):

    plugin = 'diagrameditor'
    object_types = ['image+diagram']

    validinput = r'''
digraph G {
	foo -> bar
	bar -> baz
	baz -> foo
}
'''
    invalidinput = r'sdf sdfsdf sdf'


@tests.skipUnless(InsertGNURPlotPlugin.check_dependencies_ok(),
                  'Missing dependencies')
class TestGNURPlotEditor(TestImageGeneratorPluginMixin, tests.TestCase):

    plugin = 'gnu_r_ploteditor'
    object_types = ['image+gnu_r_plot']

    validinput = r'''
x = seq(-4,4,by=0.01)
y = sin(x) + 1
plot(x,y,type='l')
'''
    invalidinput = r'sdf sdfsdf sdf'


@tests.skipUnless(InsertGnuplotPlugin.check_dependencies_ok(),
Пример #2
0
	validinput = r'''
digraph G {
	foo -> bar
	bar -> baz
	baz -> foo
}
'''
	invalidinput = r'sdf sdfsdf sdf'

	def runTest(self):
		'Test Diagram Editor plugin'
		TestGenerator._test_generator(self)


@tests.skipUnless(InsertGNURPlotPlugin.check_dependencies_ok(), 'Missing dependencies')
class TestGNURPlotEditor(TestGenerator):

	pluginklass = InsertGNURPlotPlugin
	generatorklass = GNURPlotGenerator

	validinput = r'''
x = seq(-4,4,by=0.01)
y = sin(x) + 1
plot(x,y,type='l')
'''
	invalidinput = r'sdf sdfsdf sdf'

	def runTest(self):
		'Test GNU R Plot Editor plugin'
		TestGenerator._test_generator(self)