Skip to content

Commit

Permalink
modernize mock/odoo using pyproject and fix odoo.tests import
Browse files Browse the repository at this point in the history
  • Loading branch information
petrus-v committed Oct 19, 2024
1 parent 21fae9c commit 15b5912
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 13 deletions.
3 changes: 2 additions & 1 deletion tests/mock/odoo/odoo/__init__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
from mock import MagicMock
from . import tests
from unittest.mock import MagicMock
registry = MagicMock()
tools = MagicMock()
13 changes: 13 additions & 0 deletions tests/mock/odoo/pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
[build-system]
requires = ["hatchling", "hatch-odoo"]
build-backend = "hatchling.build"

[project]
name = "odoo"
version = "0.1.0"
description = "Fake odoo used in unitest to avoid testing against real odoo"
dependencies = [
]

[tool.hatch.build]
packages = ["odoo"]
12 changes: 0 additions & 12 deletions tests/mock/odoo/setup.py

This file was deleted.

0 comments on commit 15b5912

Please sign in to comment.