Exemplo n.º 1
0
        protected Element(MSpecUnitTestProvider provider,
                          IPsi psiModuleManager,
                          ICache cacheManager,
                          Element parent,
                          ProjectModelElementEnvoy projectEnvoy,
                          IClrTypeName declaringTypeName,
                          bool isIgnored)
        {
            if (declaringTypeName == null)
            {
                throw new ArgumentNullException("declaringTypeName");
            }

            if (projectEnvoy != null)
            {
                _projectEnvoy = projectEnvoy;
            }

            _provider          = provider;
            _declaringTypeName = declaringTypeName;
            _psiModuleManager  = psiModuleManager;
            _cacheManager      = cacheManager;

            if (isIgnored)
            {
                ExplicitReason = "Ignored";
            }

            TypeName = declaringTypeName;
            Parent   = parent;

            Children     = new List <IUnitTestElement>();
            State        = UnitTestElementState.Valid;
            _taskFactory = new UnitTestTaskFactory(_provider.ID);
        }
Exemplo n.º 2
0
    protected Element(MSpecUnitTestProvider provider,
                      IPsi psiModuleManager,
                      ICache cacheManager,
                      Element parent,
                      ProjectModelElementEnvoy projectEnvoy,
                      IClrTypeName declaringTypeName,
                      bool isIgnored)
    {
      if (declaringTypeName == null)
      {
        throw new ArgumentNullException("declaringTypeName");
      }

      if (projectEnvoy != null)
      {
        _projectEnvoy = projectEnvoy;
      }

      _provider = provider;
      _declaringTypeName = declaringTypeName;
      _psiModuleManager = psiModuleManager;
      _cacheManager = cacheManager;

      if (isIgnored)
      {
        ExplicitReason = "Ignored";
      }

      TypeName = declaringTypeName;
      Parent = parent;

      Children = new List<IUnitTestElement>();
      State = UnitTestElementState.Valid;
      _taskFactory = new UnitTestTaskFactory(_provider.ID);
    }
 public BehaviorSpecificationFactory(MSpecUnitTestProvider provider,
                                     IUnitTestElementManager manager,
                                     IPsi psiModuleManager,
                                     ICache cacheManager)
 {
   _manager = manager;
   _psiModuleManager = psiModuleManager;
   _cacheManager = cacheManager;
   _provider = provider;
 }
 public BehaviorSpecificationFactory(MSpecUnitTestProvider provider,
                                     IUnitTestElementManager manager,
                                     IPsi psiModuleManager,
                                     ICache cacheManager)
 {
     _manager          = manager;
     _psiModuleManager = psiModuleManager;
     _cacheManager     = cacheManager;
     _provider         = provider;
 }
 public BehaviorFactory(MSpecUnitTestProvider provider,
                        IUnitTestElementManager manager,
                        IPsi psiModuleManager,
                        ICache cacheManager,
                        ElementCache cache)
 {
     _psiModuleManager = psiModuleManager;
     _cacheManager     = cacheManager;
     _provider         = provider;
     _cache            = cache;
     _manager          = manager;
 }
Exemplo n.º 6
0
 protected FieldElement(MSpecUnitTestProvider provider,
                        IPsi psiModuleManager,
                        ICache cacheManager,
                        Element parent,
                        ProjectModelElementEnvoy projectEnvoy,
                        IClrTypeName declaringTypeName,
                        string fieldName,
                        bool isIgnored)
   : base(provider, psiModuleManager, cacheManager, parent, projectEnvoy, declaringTypeName, isIgnored || parent.Explicit)
 {
   _fieldName = fieldName;
 }
 protected FieldElement(MSpecUnitTestProvider provider,
                        IPsi psiModuleManager,
                        ICache cacheManager,
                        Element parent,
                        ProjectModelElementEnvoy projectEnvoy,
                        IClrTypeName declaringTypeName,
                        string fieldName,
                        bool isIgnored)
     : base(provider, psiModuleManager, cacheManager, parent, projectEnvoy, declaringTypeName, isIgnored || parent.Explicit)
 {
     _fieldName = fieldName;
 }
 public ContextFactory(MSpecUnitTestProvider provider,
                       IUnitTestElementManager manager,
                       IPsi psiModuleManager,
                       ICache cacheManager,
                       ElementCache cache)
 {
   _manager = manager;
   _psiModuleManager = psiModuleManager;
   _cacheManager = cacheManager;
   _provider = provider;
   _cache = cache;
 }
Exemplo n.º 9
0
 public ContextSpecificationFactory(MSpecUnitTestProvider provider,
                                    IUnitTestElementManager manager,
                                    IPsi psiModuleManager,
                                    ICache cacheManager,
                                    ElementCache cache)
 {
     _manager          = manager;
     _psiModuleManager = psiModuleManager;
     _cacheManager     = cacheManager;
     _provider         = provider;
     _cache            = cache;
 }
 public ContextSpecificationElement(MSpecUnitTestProvider provider,
                                    IPsi psiModuleManager,
                                    ICache cacheManager,
                                    ProjectModelElementEnvoy project,
                                    ContextElement context,
                                    IClrTypeName declaringTypeName,
                                    string fieldName,
                                    bool isIgnored)
     : base(provider,
            psiModuleManager,
            cacheManager,
            context,
            project,
            declaringTypeName,
            fieldName,
            isIgnored || context.Explicit)
 {
     _id = CreateId(context, fieldName);
 }
 public ContextSpecificationElement(MSpecUnitTestProvider provider,
                                    IPsi psiModuleManager,
                                    ICache cacheManager,
                                    ProjectModelElementEnvoy project,
                                    ContextElement context,
                                    IClrTypeName declaringTypeName,
                                    string fieldName,
                                    bool isIgnored)
   : base(provider,
          psiModuleManager,
          cacheManager,
          context,
          project,
          declaringTypeName,
          fieldName,
          isIgnored || context.Explicit)
 {
   _id = CreateId(context, fieldName);
 }
 public BehaviorSpecificationElement(MSpecUnitTestProvider provider,
                                     IPsi psiModuleManager,
                                     ICache cacheManager,
                                     ProjectModelElementEnvoy projectEnvoy,
                                     BehaviorElement behavior,
                                     IClrTypeName declaringTypeName,
                                     string fieldName,
                                     bool isIgnored
   )
   : base(provider,
          psiModuleManager,
          cacheManager,
          behavior,
          projectEnvoy,
          declaringTypeName,
          fieldName,
          isIgnored || behavior.Explicit)
 {
   _id = CreateId(behavior, fieldName);
 }
Exemplo n.º 13
0
    public ContextElement(MSpecUnitTestProvider provider,
                          IPsi psiModuleManager,
                          ICache cacheManager,
                          ProjectModelElementEnvoy projectEnvoy,
                          IClrTypeName typeName,
                          string assemblyLocation,
                          string subject,
                          IEnumerable<string> tags,
                          bool isIgnored)
      : base(provider, psiModuleManager, cacheManager, null, projectEnvoy, typeName, isIgnored)
    {
      _id = CreateId(subject, TypeName.FullName, tags);
      _assemblyLocation = assemblyLocation;
      _subject = subject;

      if (tags != null)
      {
        _categories = UnitTestElementCategory.Create(new JetHashSet<string>(tags));
      }
    }
Exemplo n.º 14
0
 public BehaviorSpecificationElement(MSpecUnitTestProvider provider,
                                     IPsi psiModuleManager,
                                     ICache cacheManager,
                                     ProjectModelElementEnvoy projectEnvoy,
                                     BehaviorElement behavior,
                                     IClrTypeName declaringTypeName,
                                     string fieldName,
                                     bool isIgnored
                                     )
     : base(provider,
            psiModuleManager,
            cacheManager,
            behavior,
            projectEnvoy,
            declaringTypeName,
            fieldName,
            isIgnored || behavior.Explicit)
 {
     _id = CreateId(behavior, fieldName);
 }
        public ContextElement(MSpecUnitTestProvider provider,
                              IPsi psiModuleManager,
                              ICache cacheManager,
                              ProjectModelElementEnvoy projectEnvoy,
                              IClrTypeName typeName,
                              string assemblyLocation,
                              string subject,
                              IEnumerable <string> tags,
                              bool isIgnored)
            : base(provider, psiModuleManager, cacheManager, null, projectEnvoy, typeName, isIgnored)
        {
            _id = CreateId(subject, TypeName.FullName, tags);
            _assemblyLocation = assemblyLocation;
            _subject          = subject;

            if (tags != null)
            {
                _categories = UnitTestElementCategory.Create(new JetHashSet <string>(tags));
            }
        }
 public BehaviorElement(MSpecUnitTestProvider provider,
                        IPsi psiModuleManager,
                        ICache cacheManager,
                        // ReSharper disable SuggestBaseTypeForParameter
                        ContextElement context,
                        // ReSharper restore SuggestBaseTypeForParameter
                        ProjectModelElementEnvoy projectEnvoy,
                        IClrTypeName declaringTypeName,
                        string fieldName,
                        bool isIgnored,
                        string fieldType)
     : base(provider,
            psiModuleManager,
            cacheManager,
            context,
            projectEnvoy,
            declaringTypeName,
            fieldName,
            isIgnored || context.Explicit)
 {
     FieldType = fieldType;
     _id       = CreateId(context, fieldType, fieldName);
 }
 public BehaviorElement(MSpecUnitTestProvider provider,
                        IPsi psiModuleManager,
                        ICache cacheManager,
                        // ReSharper disable SuggestBaseTypeForParameter
                        ContextElement context,
                        // ReSharper restore SuggestBaseTypeForParameter
                        ProjectModelElementEnvoy projectEnvoy,
                        IClrTypeName declaringTypeName,
                        string fieldName,
                        bool isIgnored,
                        string fieldType)
   : base(provider,
          psiModuleManager,
          cacheManager,
          context,
          projectEnvoy,
          declaringTypeName,
          fieldName,
          isIgnored || context.Explicit)
 {
   FieldType = fieldType;
   _id = CreateId(context, fieldType, fieldName);
 }