summaryrefslogtreecommitdiff
path: root/src/Parser.hs
diff options
context:
space:
mode:
authorRoman Smrž <roman.smrz@seznam.cz>2023-03-26 21:34:44 +0200
committerRoman Smrž <roman.smrz@seznam.cz>2023-03-28 22:10:06 +0200
commitc9a90244a7b4f9c752541c5ff19616f7ff980ee4 (patch)
treeefe53e9eab497f446538c9171c77dd3a66468f3f /src/Parser.hs
parenta76fa89bf612f39a053390dfe1c78ba1f9331bd8 (diff)
Network subnets and routing
Diffstat (limited to 'src/Parser.hs')
-rw-r--r--src/Parser.hs7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/Parser.hs b/src/Parser.hs
index b79931b..aafba2c 100644
--- a/src/Parser.hs
+++ b/src/Parser.hs
@@ -630,6 +630,12 @@ testWith = do
modify $ \s -> s { testContext = ctx }
testBlock indent
+testSubnet :: TestParser [TestStep]
+testSubnet = command "subnet" $ Subnet
+ <$> param ""
+ <*> paramOrContext "of"
+ <*> innerBlock
+
testNode :: TestParser [TestStep]
testNode = command "node" $ DeclNode
<$> param ""
@@ -690,6 +696,7 @@ testStep = choice
, forStatement
, testLocal
, testWith
+ , testSubnet
, testNode
, testSpawn
, testSend