code: def test_validate_env_vars(self):
      # happy path
      env_vars = {
          "TYPICAL_KEY_1": "TYPICAL_VALUE_1",
          "_typical_key_2": "typical_value_2",
      }
      validate_env_vars(env_vars)
  
      # keys with wrong type
      mistyped_keys = [1, tuple(), b"old_school"]
      for k in mistyped_keys:
          with self.assertRaises(MetaflowException):
              validate_env_vars({k: "v"})
  
      # values with wrong type
      mistyped_values = [1, {}, b"old_school"]
      for i, v in enumerate(mistyped_values):
          with self.assertRaises(MetaflowException):
              validate_env_vars({f"K{i}": v})
  
      # weird keys
      weird_keys = [
          "1_",
          "hello world",
          "hey_arnold!",
          "I_\u2665_NY",
          "door-",
          "METAFLOW_SOMETHING_OR_OTHER",
      ]
      for k in weird_keys:
          with self.assertRaises(MetaflowException):
              validate_env_vars({k: "v"})
  
file_path: metaflow/test/unit/test_secrets_decorator.py
imports: import os
  import time
  import unittest
  from unittest.mock import patch
  from metaflow.exception import MetaflowException
  import metaflow.metaflow_config
  from metaflow.plugins.secrets.secrets_decorator import SecretSpec, validate_env_vars_across_secrets, validate_env_vars_vs_existing_env, validate_env_vars, get_secrets_backend_provider
label_desc: Use image node_id 3 for calling the TestEnvVarValidations obj's underlying member method code with example usage: obj.test_validate_env_vars() without return types