more complexity to test case
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
from appdaemon.adapi import ADAPI
|
||||
|
||||
class DatabaseApp(ADAPI):
|
||||
def initialize(self):
|
||||
self.log(f'Initialized from {__file__}')
|
||||
|
||||
|
||||
class Database:
|
||||
def __init__(self, ad: ADAPI) -> None:
|
||||
self.ad = ad
|
||||
|
||||
@@ -14,4 +14,8 @@ Hello:
|
||||
module: hello
|
||||
class: HelloWorld
|
||||
|
||||
globals:
|
||||
module: globals
|
||||
global: true
|
||||
|
||||
# Foo: bar
|
||||
1
apps/globals/globals.py
Normal file
1
apps/globals/globals.py
Normal file
@@ -0,0 +1 @@
|
||||
GLOBAL_CONSTANT = True
|
||||
9
apps/test/test.py
Normal file
9
apps/test/test.py
Normal file
@@ -0,0 +1,9 @@
|
||||
from app1.database import Database
|
||||
from appdaemon.adbase import ADBase
|
||||
|
||||
|
||||
class Test(ADBase):
|
||||
def initialize(self):
|
||||
self.adapi = self.get_ad_api()
|
||||
self.database = Database(self.adapi)
|
||||
# self.notify.send("Test message from Test2 app.")
|
||||
4
apps/test/test.yaml
Normal file
4
apps/test/test.yaml
Normal file
@@ -0,0 +1,4 @@
|
||||
test:
|
||||
module: test
|
||||
class: Test
|
||||
log_level: DEBUG
|
||||
Reference in New Issue
Block a user