Exemple #1
0
 def check_static(self, filename):
     f = os.path.join(self.folder, filename)
     linker = Linker(f, no_comments=False)
     linker.link()
     orig = open(os.path.join(self.folder, '_%s.orig' % filename)).read()
     test = open(os.path.join(self.folder, '_%s' % filename)).read()
     self.assertEqual(test, orig)
Exemple #2
0
    def test_zeta(self):
        folder = os.path.join(BASEDIR, 'zeta')

        css_file = os.path.join(folder, 'main.css')
        linker = Linker(css_file, no_comments=False)
        linker.link()
        orig = open(os.path.join(folder, '_main.css.orig')).read()
        test = open(os.path.join(folder, '_main.css')).read()
        self.assertEqual(test, orig)

        js_file = os.path.join(folder, 'main.js')
        linker = Linker(js_file, no_comments=False)
        linker.link()
        orig = open(os.path.join(folder, '_main.js.orig')).read()
        test = open(os.path.join(folder, '_main.js')).read()
        self.assertEqual(test, orig)