# yaml-language-server: $schema=https://api.cerbos.dev/latest/cerbos/policy/v1/TestSuite.schema.json
---
name: DemoBasicTenantHierarchyTestSuite
description: Tests for verifying the demo_basic_tenant_hierarchy resource policy
tests:
  - name: Hyping a DemoBasicTenantHierarchy
    input:
      principals:
        - jess
        - todd
      resources:
        - demo_basic_tenant_hierarchy_12345
        - demo_basic_tenant_hierarchy_67890
      actions:
        - hype
    expected:
      - principal: jess
        resource: demo_basic_tenant_hierarchy_12345
        actions:
          hype: EFFECT_ALLOW
      - principal: jess
        resource: demo_basic_tenant_hierarchy_67890
        actions:
          hype: EFFECT_DENY
      - principal: todd
        resource: demo_basic_tenant_hierarchy_12345
        actions:
          hype: EFFECT_DENY
      - principal: todd
        resource: demo_basic_tenant_hierarchy_67890
        actions:
          hype: EFFECT_ALLOW
