mirror of
https://github.com/ansible/awx.git
synced 2026-02-26 07:26:03 -03:30
Addd inventory fixture
This commit is contained in:
@@ -1,8 +1,10 @@
|
||||
import pytest
|
||||
|
||||
from awx.main.models.credential import Credential
|
||||
from awx.main.models.inventory import Inventory
|
||||
from awx.main.models.organization import (
|
||||
Organization,
|
||||
Permission,
|
||||
Team,
|
||||
)
|
||||
from django.contrib.auth.models import User
|
||||
@@ -30,6 +32,10 @@ def organization():
|
||||
def credential():
|
||||
return Credential.objects.create(kind='aws', name='test-cred')
|
||||
|
||||
@pytest.fixture
|
||||
def inventory(organization):
|
||||
return Inventory.objects.create(name="test-inventory", organization=organization)
|
||||
|
||||
@pytest.fixture
|
||||
def permissions():
|
||||
return {
|
||||
|
||||
Reference in New Issue
Block a user