Refactor schemata not to import objects but modules
Change-Id: Id328de900fa6b870653de2a01f4d54eb84df3894 Signed-off-by: Taku Fukushima <f.tac.mac@gmail.com>
This commit is contained in:
parent
5a855e0065
commit
b3dd4db50e
@ -10,8 +10,16 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
from kuryr.schemata.endpoint_create import ENDPOINT_CREATE_SCHEMA # noqa
|
||||
from kuryr.schemata.endpoint_delete import ENDPOINT_DELETE_SCHEMA # noqa
|
||||
from kuryr.schemata.join import JOIN_SCHEMA # noqa
|
||||
from kuryr.schemata.network_create import NETWORK_CREATE_SCHEMA # noqa
|
||||
from kuryr.schemata.network_delete import NETWORK_DELETE_SCHEMA # noqa
|
||||
from kuryr.schemata import endpoint_create
|
||||
from kuryr.schemata import endpoint_delete
|
||||
from kuryr.schemata import join
|
||||
from kuryr.schemata import network_create
|
||||
from kuryr.schemata import network_delete
|
||||
|
||||
|
||||
# Aliases for schemata in each module
|
||||
ENDPOINT_CREATE_SCHEMA = endpoint_create.ENDPOINT_CREATE_SCHEMA
|
||||
ENDPOINT_DELETE_SCHEMA = endpoint_delete.ENDPOINT_DELETE_SCHEMA
|
||||
JOIN_SCHEMA = join.JOIN_SCHEMA
|
||||
NETWORK_CREATE_SCHEMA = network_create.NETWORK_CREATE_SCHEMA
|
||||
NETWORK_DELETE_SCHEMA = network_delete.NETWORK_DELETE_SCHEMA
|
||||
|
@ -10,7 +10,7 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
from kuryr.schemata.commons import COMMONS
|
||||
from kuryr.schemata import commons
|
||||
|
||||
ENDPOINT_CREATE_SCHEMA = {
|
||||
u'links': [{
|
||||
@ -48,4 +48,4 @@ ENDPOINT_CREATE_SCHEMA = {
|
||||
}
|
||||
}
|
||||
|
||||
ENDPOINT_CREATE_SCHEMA[u'definitions'][u'commons'] = COMMONS
|
||||
ENDPOINT_CREATE_SCHEMA[u'definitions'][u'commons'] = commons.COMMONS
|
||||
|
@ -10,7 +10,7 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
from kuryr.schemata.commons import COMMONS
|
||||
from kuryr.schemata import commons
|
||||
|
||||
ENDPOINT_DELETE_SCHEMA = {
|
||||
u'links': [{
|
||||
@ -37,4 +37,4 @@ ENDPOINT_DELETE_SCHEMA = {
|
||||
}
|
||||
}
|
||||
|
||||
ENDPOINT_DELETE_SCHEMA[u'definitions'][u'commons'] = COMMONS
|
||||
ENDPOINT_DELETE_SCHEMA[u'definitions'][u'commons'] = commons.COMMONS
|
||||
|
@ -10,7 +10,7 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
from kuryr.schemata.commons import COMMONS
|
||||
from kuryr.schemata import commons
|
||||
|
||||
NETWORK_CREATE_SCHEMA = {
|
||||
u'links': [{
|
||||
@ -37,4 +37,4 @@ NETWORK_CREATE_SCHEMA = {
|
||||
}
|
||||
}
|
||||
|
||||
NETWORK_CREATE_SCHEMA[u'definitions'][u'commons'] = COMMONS
|
||||
NETWORK_CREATE_SCHEMA[u'definitions'][u'commons'] = commons.COMMONS
|
||||
|
@ -10,7 +10,7 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
from kuryr.schemata.commons import COMMONS
|
||||
from kuryr.schemata import commons
|
||||
|
||||
NETWORK_DELETE_SCHEMA = {
|
||||
u'links': [{
|
||||
@ -33,4 +33,4 @@ NETWORK_DELETE_SCHEMA = {
|
||||
}
|
||||
}
|
||||
|
||||
NETWORK_DELETE_SCHEMA[u'definitions'][u'commons'] = COMMONS
|
||||
NETWORK_DELETE_SCHEMA[u'definitions'][u'commons'] = commons.COMMONS
|
||||
|
Loading…
Reference in New Issue
Block a user