gisce / destral Goto Github PK
View Code? Open in Web Editor NEWPowERP testing framework
Home Page: http://destral.readthedocs.org/
License: GNU General Public License v3.0
PowERP testing framework
Home Page: http://destral.readthedocs.org/
License: GNU General Public License v3.0
After #73 we need to show which are the missing strings
Find if spec
directory is found and then run mamba suite
Raise error if no permissions are defined
I am not sure if this is possible, but each time a test run starts it installs the module and all their dependencies, when may be it is not required when the database already exists. This is takes a lot of time and makes unit testing tedious.
I tried commenting line 51 (self.openerp.install_module(self.config['module'])) and the speed improvement is huge!
I propose two possible solutions that:
When testing the module "base_extended", the .pot file generated in the test contains strings from module "base" and it should only contain strings from "base_extended"; like the .pot file generated from the ERP (Administration->Translations->Import/Export...).
Same with giscedata_ot_facturacio and giscedata_ot
When using --no-drodb
the user admin
is initialized without password.
If we have demo data check all the reports defined in the module with that demo data
Force the translation of all the strings from a module
Execute destral with multiprocess on 1 process:
PROS:
When module haven't got tests, dropdb after test_all_views fails
Circle CI supports tests metadata which inform the failed tests, slower tests, etc.
This metada uses Junit XML format
We have two options:
Please could you take a look at https://drone.gisce.net/gisce/erp/5020
Especially to:
2017-07-03 09:15:29,584:INFO:destral.utils.compare_pofiles:Could not get po/pot file: /drone/src/github.com/gisce/erp/server/bin/addons/giscedata_perfils/i18n/[.po
AssertionError: There are -1 missing strings in the PO file of the module giscedata_perfils
But maybe is a testing suite configuration problem.
When tests of different modules are passed, the db is reused for each one, sometimes it can lead to problems in the tests because another module has extended or modified the scheme of some tables
To ensure https://github.com/gisce/erp/pull/3484
Mamba, the test runner, is discontinued (no compatibilitat with python >= 3.8)
nestorsalceda/mamba#143
So we have to considerate unittest, pytest...
For now if we want to patch the creation of new cursors inside a test we have to do:
with Transaction().start(self.database) as txn:
with PatchNewCursors():
...
Maybe we can add the possibillity in creation a new Transaction to define to use PatchedCursors
as
with Transaction(same_cursor=True).start(self.database) as txn:
...
You can see at https://github.com/gisce/erp/pull/4841
With an environment variable DESTRAL_FORCE_DATABASE
then use this database and not deleting it when the test is finished.
Integration with https://github.com/PyCQA/pycodestyle
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.