Code Monkey home page Code Monkey logo

odoo-tester's Introduction

Odoo automated unit test runner

This is a recipe for building a Docker container suitable for running automated unit tests on Odoo modules. The container is built using Fedora and the latest Odoo branch. Almost all dependencies are provided using official Fedora packages.

The resulting container is published on Docker Hub as unipartdigital/odoo-tester:14.0.

Building

To build and publish the container image:

docker build -t unipartdigital/odoo-tester:14.0 .
docker push unipartdigital/odoo-tester:14.0

Running

To run Odoo within the container:

docker run -it --rm unipartdigital/odoo-tester:14.0

Any extra arguments will be appended to the odoo-bin command line. For example, to install the product module:

docker run -it --rm unipartdigital/odoo-tester:14.0 -i product

Extending

The primary use case for this container image is to allow for the automated testing of external Odoo modules. An external module may include a Dockerfile such as:

FROM unipartdigital/odoo-tester:14.0
ADD addons/my_module /opt/odoo-addons/my_module
CMD ["--test-enable", "-i", "my_module"]

Tests can then be run (from within the external module's directory) using:

docker build -t my_module-tester .
docker run -it --rm my_module-tester

These commands can be invoked as part of a continuous integration system such as Travis CI, to ensure that the module's automated tests are run automatically for every commit and pull request.

odoo-tester's People

Contributors

mcb30 avatar ws-mps avatar adamrpatrick avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.