Browse Source

test

pull/636/head
archetipo 9 years ago
committed by Dave Lasley
parent
commit
ed537954e5
  1. 4
      auto_backup/__openerp__.py
  2. 16
      auto_backup/tests/test_auto_backup.py

4
auto_backup/__openerp__.py

@ -31,9 +31,7 @@
"category" : "Tools", "category" : "Tools",
"summary": "Backups data base", "summary": "Backups data base",
"depends" : ['base','email_template'], "depends" : ['base','email_template'],
"demo_xml" : [
"data/backup_data.xml"
],
"demo" : [],
"data" : [ "data" : [
"view/bkp_conf_view.xml", "view/bkp_conf_view.xml",
"data/backup_data.xml", "data/backup_data.xml",

16
auto_backup/tests/test_auto_backup.py

@ -46,19 +46,3 @@ class TestsAutoBackup(common.TransactionCase):
} }
) )
self.assertEqual(this.host, 'localhost') self.assertEqual(this.host, 'localhost')
cronbk = self.cron_model.search([('name', '=', 'Backup scheduler')])
import pdb;pdb.set_trace()
cronbk.write(
{
'active': True,
'doall': True
}
)
filetime = (
datetime.now() + timedelta(minutes=1)
).strftime('%d_%m_%Y_%H_%M_%S')
bkp_file = '%s_%s.dimp.zip' % (
filetime, this.name)
file_path = os.path.join(this.bkp_dir, bkp_file)
self.assertEqual(os.path.isfile(file_path), True)
Loading…
Cancel
Save