Relation support for multi-charm VNFs
[osm/N2VC.git] / tests / charms / layers / native-ci / reactive / native-ci.py
index 17bf5f4..9e5fe67 100644 (file)
@@ -42,3 +42,21 @@ def testint():
         action_set({'output': intval})
     finally:
         clear_flag('actions.testint')
+
+
+@when('db.joined')
+def provides_db(db):
+    """Simulate providing database credentials."""
+    db.configure(
+        database="mydb",
+        user="myuser",
+        password="mypassword",
+        host="myhost",
+        slave="myslave",
+    )
+
+
+@when('db.available')
+def requires_db(db):
+    """Simulate receiving database credentials."""
+    pass