Перейти к содержимому
Меню
Чтобы взаимодействовать с сообществом, необходимо зарегистрироваться.
Этот вопрос был отмечен
1986 Представления

I am new to odoo. I am trying to test a custom module. But the test doesn't run.

Here is the file structure 


```
course_management
|-- ...
`-- tests
|-- __init__.py
|-- test_course_management_course.py
```


Here is the the content of test_course_management_course.py file 


from odoo.tests import common

```
from odoo.tests import common


class TestCourseManagement(common.TransactionCase):

def test_creation_end_date(self):
test_course = self.env['course.management.course'].create({
'name': 'TestProjectfromtestcase'
})
self.assertEqual(test_course.name, 'TestProject')

```


And the commands I have tried are as follows

```
./odoo-bin -c /home/bs632/odoo.conf -u course_management --test-enable -d testDB


./odoo-bin -c /home/bs632/odoo.conf --log-level=test -u course_management --test-enable -d testDB --test-report-directory=./testlog.


./odoo-bin -c /home/bs632/odoo.conf --log-level=test -u course_management --test-enable -d testDB


./odoo-bin -c /home/bs632/odoo.conf --log-level=test -i course_management --test-enable -d testDB
```

But the test doesn't run.


Аватар
Отменить
Related Posts Ответы Просмотры Активность
0
авг. 21
4
3
мая 18
4761
0
июн. 25
2726
2
авг. 24
2484
1
мар. 24
3089