joey shelton / LED_Demo

Dependencies:   MAX44000 PWM_Tone_Library nexpaq_mdk

Fork of LED_Demo by Maxim nexpaq

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers test_data.py Source File

test_data.py

00001 # This tests overriding configuration values based on target labels.
00002 # Four targets are defined:
00003 #    - "base" is the base target, it doesn't define any extra labels
00004 #    - "b1" inherits from "base" and adds the "b1_label" label
00005 #    - "b2" inherits from "base" and adds the "b2_label" label
00006 #    - "both" inherits from both "b1" and "b2", so it inherits both labels
00007 
00008 expected_results = {
00009     "b1": {
00010         "desc": "override values based on labels (first label)",
00011         "app.app1": "v_app1[b1_label]",
00012         "app.app2": "v_app2"
00013     },
00014     "b2": {
00015         "desc": "override values based on labels (second label)",
00016         "app.app1": "v_app1",
00017         "app.app2": "v_app2[b2_label]"
00018     },
00019     "both": {
00020         "desc": "override values based on labels (both labels)",
00021         "app.app1": "v_app1[b1_label]",
00022         "app.app2": "v_app2[b2_label]"
00023     },
00024     "base": {
00025         "desc": "override values based on labels (no labels)",
00026         "app.app1": "v_app1",
00027         "app.app2": "v_app2"
00028     }
00029 }