Update devref examples about alembic migrations
Because model_base.py is now in neutron-lib. Change-Id: I4e508a9c88af1017ffa20f5346e3c859c5236223
This commit is contained in:
parent
310f83bc4e
commit
07c8e144d7
@ -52,14 +52,15 @@ Steps for implementing the test
|
|||||||
Create a module ``networking_foo/db/models/head.py`` with the following
|
Create a module ``networking_foo/db/models/head.py`` with the following
|
||||||
content: ::
|
content: ::
|
||||||
|
|
||||||
from neutron.db.migration.models import head
|
from neutron_lib.db import model_base
|
||||||
|
|
||||||
from networking_foo import models # noqa
|
from networking_foo import models # noqa
|
||||||
# Alternatively, import separate modules here if the models are not in one
|
# Alternatively, import separate modules here if the models are not in one
|
||||||
# models.py file
|
# models.py file
|
||||||
|
|
||||||
|
|
||||||
def get_metadata():
|
def get_metadata():
|
||||||
return head.model_base.BASEV2.metadata
|
return model_base.BASEV2.metadata
|
||||||
|
|
||||||
|
|
||||||
2. Implement the test module
|
2. Implement the test module
|
||||||
|
Loading…
x
Reference in New Issue
Block a user