text: # Copyright 2016-2020 Swiss National Supercomputing Centre (CSCS/ETH Zurich)
  # ReFrame Project Developers. See the top-level LICENSE file for details.
  #
  # SPDX-License-Identifier: BSD-3-Clause
  
  #
  # Minimal CSCS configuration for testing the Torque backend
  #
  
  
  class ReframeSettings:
      job_poll_intervals = [1, 2, 3]
      job_submit_timeout = 60
      checks_path = ['checks/']
      checks_path_recurse = True
      site_configuration = {
          'systems': {
              'dom': {
                  'descr': 'Dom TDS',
                  'hostnames': ['dom'],
                  'modules_system': 'tmod',
                  'resourcesdir': '/apps/common/UES/reframe/resources',
                  'partitions': {
                      'login': {
                          'scheduler': 'local',
                          'modules': [],
                          'access':  [],
                          'environs': ['PrgEnv-cray', 'PrgEnv-gnu',
                                       'PrgEnv-intel', 'PrgEnv-pgi'],
                          'descr': 'Login nodes',
                          'max_jobs': 4
                      },
  
                      'gpu': {
                          'scheduler': 'torque+mpiexec',
                          'modules': ['daint-gpu'],
                          'access':  ['-l proc=gpu'],
                          'environs': ['PrgEnv-cray', 'PrgEnv-gnu',
                                       'PrgEnv-intel', 'PrgEnv-pgi'],
                          'descr': 'Hybrid nodes (Haswell/P100)',
                          'max_jobs': 100,
                      },
  
                      'mc': {
                          'scheduler': 'torque+mpiexec',
                          'modules': ['daint-mc'],
                          'access':  ['-l proc=mc'],
                          'environs': ['PrgEnv-cray', 'PrgEnv-gnu',
                                       'PrgEnv-intel', 'PrgEnv-pgi'],
                          'descr': 'Multicore nodes (Broadwell)',
                          'max_jobs': 100,
                      },
                  }
              },
  
              'generic': {
                  'descr': 'Generic example system',
                  'partitions': {
                      'login': {
                          'scheduler': 'local',
                          'modules': [],
                          'access': [],
                          'environs': ['builtin-gcc'],
                          'descr': 'Login nodes'
                      }
                  }
              }
          },
  
          'environments': {
              '*': {
                  'PrgEnv-cray': {
                      'modules': ['PrgEnv-cray'],
                  },
  
                  'PrgEnv-gnu': {
                      'modules': ['PrgEnv-gnu'],
                  },
  
                  'PrgEnv-intel': {
                      'modules': ['PrgEnv-intel'],
                  },
  
                  'PrgEnv-pgi': {
                      'modules': ['PrgEnv-pgi'],
                  },
  
                  'builtin': {
                      'cc':  'cc',
                      'cxx': '',
                      'ftn': '',
                  },
  
                  'builtin-gcc': {
                      'cc':  'gcc',
                      'cxx': 'g++',
                      'ftn': 'gfortran',
                  }
              }
          },
      }
  
      logging_config = {
          'level': 'DEBUG',
          'handlers': [
              {
                  'type': 'file',
                  'name': 'reframe.log',
                  'level': 'DEBUG',
                  'format': '[%(asctime)s] %(levelname)s: '
                            '%(check_info)s: %(message)s',
                  'append': False,
              },
  
              # Output handling
              {
                  'type': 'stream',
                  'name': 'stdout',
                  'level': 'INFO',
                  'format': '%(message)s'
              },
              {
                  'type': 'file',
                  'name': 'reframe.out',
                  'level': 'INFO',
                  'format': '%(message)s',
                  'append': False,
              }
          ]
      }
  
      perf_logging_config = {
          'level': 'DEBUG',
          'handlers': [
              {
                  'type': 'filelog',
                  'prefix': '%(check_system)s/%(check_partition)s',
                  'level': 'INFO',
                  'format': (
                      '%(check_job_completion_time)s|reframe %(version)s|'
                      '%(check_info)s|jobid=%(check_jobid)s|'
                      'num_tasks=%(check_num_tasks)s|'
                      '%(check_perf_var)s=%(check_perf_value)s|'
                      'ref=%(check_perf_ref)s '
                      '(l=%(check_perf_lower_thres)s, '
                      'u=%(check_perf_upper_thres)s)'
                  ),
                  'datefmt': '%FT%T%:z',
                  'append': True
              }
          ]
      }
  
  
  settings = ReframeSettings()
  