Files
regorus/tests/parser/cases/expressions/arithmetic.yaml
Ming-Wei Shih c0972ad2ba Update license to MIT
Signed-off-by: Ming-Wei Shih <mishih@microsoft.com>
2023-02-09 19:40:35 +00:00

41 lines
1.0 KiB
YAML

# Copyright (c) Microsoft Corporation.
# Licensed under the MIT License.
cases:
- note: basic
rego: |
package test
x = 1 - 2 * 3 / 4 + 2
policy:
- spec:
head:
compr:
refr:
var: x
assign:
op: =
value:
arithexpr:
op: +
lhs:
arithexpr:
op: "-"
lhs:
number: 1
rhs:
arithexpr:
op: "/"
lhs:
arithexpr:
op: "*"
lhs:
number: 2
rhs:
number: 3
rhs:
number: 4
rhs:
number: 2
bodies: []