code: def test_view_table(allow, expected_anon, expected_auth):
      with make_app_client(
          config={
              "databases": {
                  "fixtures": {
                      "tables": {
                          "compound_three_primary_keys": {
                              "allow": allow
                          }
                      }
                  }
              }
          }
      ) as client:
          anon_response = client.get(
              "/fixtures/compound_three_primary_keys"
          )
          assert expected_anon == anon_response.status
          if allow and anon_response.status == 200:
              # Should be no padlock
              assert (
                  ">compound_three_primary_keys 🔒</h1>"
                  not in anon_response.text
              )
          auth_response = client.get(
              "/fixtures/compound_three_primary_keys",
              cookies={"ds_actor": client.actor_cookie({"id": "root"})},
          )
          assert expected_auth == auth_response.status
          if allow and expected_anon == 403 and expected_auth == 200:
              assert (
                  ">compound_three_primary_keys 🔒</h1>"
                  in auth_response.text
              )
  
imports: import collections
  from datasette.app import Datasette
  from datasette.cli import cli
  from datasette.default_permissions import restrictions_allow_action
  from .fixtures import app_client, assert_permissions_checked, make_app_client
  from click.testing import CliRunner
  from bs4 import BeautifulSoup
  import copy
  import json
  from pprint import pprint
  import pytest_asyncio
  import pytest
  import re
  import time
  import urllib
label_desc: Use image node_id 6 for calling a global function with example usage: test_view_table(allow, expected_anon, expected_auth) without return types