コード例 #1
0
'''
    invalidinput = r'sdf sdfsdf sdf'


@tests.skipUnless(InsertGnuplotPlugin.check_dependencies_ok(),
                  'Missing dependencies')
class TestGnuplotEditor(TestImageGeneratorPluginMixin, tests.TestCase):

    plugin = 'gnuplot_ploteditor'
    object_types = ['image+gnuplot']

    validinput = r'plot sin(x), cos(x)'
    invalidinput = r'sdf sdfsdf sdf'


@tests.skipUnless(InsertScorePlugin.check_dependencies_ok(),
                  'Missing dependencies')
class TestScoreEditor(TestImageGeneratorPluginMixin, tests.TestCase):

    plugin = 'scoreeditor'
    object_types = ['image+score']

    validinput = r'''
\version "2.18.2"
\relative c {
        \clef bass
        \key d \major
        \time 4/4

        d4 a b fis
        g4 d g a
コード例 #2
0
@tests.skipUnless(InsertGnuplotPlugin.check_dependencies_ok(), 'Missing dependencies')
class TestGnuplotEditor(TestGenerator):

	pluginklass = InsertGnuplotPlugin
	generatorklass = GnuplotGenerator

	validinput = r'plot sin(x), cos(x)'
	invalidinput = r'sdf sdfsdf sdf'

	def testGenerator(self):
		'Test Gnuplot Plot Editor plugin'
		TestGenerator._test_generator(self)


@tests.skipUnless(InsertScorePlugin.check_dependencies_ok(), 'Missing dependencies')
class TestScoreEditor(TestGenerator):

	pluginklass = InsertScorePlugin
	generatorklass = ScoreGenerator

	validinput = r'''
\relative c {
        \clef bass
        \key d \major
        \time 4/4

        d4 a b fis
        g4 d g a
}
'''