mirror of
https://github.com/gsi-upm/senpy
synced 2024-12-21 12:38:13 +00:00
use default strict for extension tests
This commit is contained in:
parent
e324c730e2
commit
b33a70620b
@ -20,6 +20,7 @@ It orchestrates plugin (de)activation and analysis.
|
||||
from future import standard_library
|
||||
standard_library.install_aliases()
|
||||
|
||||
from . import config
|
||||
from . import plugins, api
|
||||
from .models import Error, AggregatedEvaluation
|
||||
from .plugins import AnalysisPlugin
|
||||
@ -45,9 +46,10 @@ class Senpy(object):
|
||||
plugin_folder=".",
|
||||
data_folder=None,
|
||||
install=False,
|
||||
strict=True,
|
||||
strict=None,
|
||||
default_plugins=False):
|
||||
|
||||
|
||||
default_data = os.path.join(os.getcwd(), 'senpy_data')
|
||||
self.data_folder = data_folder or os.environ.get('SENPY_DATA', default_data)
|
||||
try:
|
||||
@ -59,7 +61,7 @@ class Senpy(object):
|
||||
raise
|
||||
|
||||
self._default = None
|
||||
self.strict = strict
|
||||
self.strict = strict if strict is not None else config.strict
|
||||
self.install = install
|
||||
self._plugins = {}
|
||||
if plugin_folder:
|
||||
|
@ -22,9 +22,8 @@ import logging
|
||||
|
||||
from functools import partial
|
||||
from senpy.extensions import Senpy
|
||||
from senpy import plugins
|
||||
from senpy import plugins, config, api
|
||||
from senpy.models import Error, Results, Entry, EmotionSet, Emotion, Plugin
|
||||
from senpy import api
|
||||
from flask import Flask
|
||||
from unittest import TestCase
|
||||
|
||||
@ -260,4 +259,4 @@ class ExtensionsTest(TestCase):
|
||||
'''The default set of plugins should all load'''
|
||||
self.app = Flask('test_extensions')
|
||||
self.examples_dir = os.path.join(os.path.dirname(__file__), '..', 'example-plugins')
|
||||
self.senpy = Senpy(app=self.app, default_plugins=False, strict=True)
|
||||
self.senpy = Senpy(app=self.app, default_plugins=False)
|
||||
|
Loading…
Reference in New Issue
Block a user