public Ps1ScaffolderLocator(IPowershellCommandInvoker commandInvoker, IPackageManager packageManager, IPackagePathResolver pathResolver, FileSystem.IFileSystem fileSystem, IScaffoldingConfigStore configStore)
 {
     _commandInvoker = commandInvoker;
     _packageManager = packageManager;
     _pathResolver = pathResolver ?? packageManager.PathResolver;
     _fileSystem = fileSystem;
     _configStore = configStore;
 }
 public Ps1ScaffolderLocator(IPowershellCommandInvoker commandInvoker, IPackageManager packageManager, IPackagePathResolver pathResolver, FileSystem.IFileSystem fileSystem, IScaffoldingConfigStore configStore)
 {
     _commandInvoker = commandInvoker;
     _packageManager = packageManager;
     _pathResolver   = pathResolver ?? packageManager.PathResolver;
     _fileSystem     = fileSystem;
     _configStore    = configStore;
 }
Ejemplo n.º 3
0
        private RaspberryIRDotNet.TX.PulseSpaceTransmitter_AutoOpenClose MakeSubject(FileSystem.IFileSystem fileSystem)
        {
            var subject = new RaspberryIRDotNet.TX.PulseSpaceTransmitter_AutoOpenClose()
            {
                TransmissionDevice = LircPath
            };

            subject.SetFileSystem(fileSystem);
            return(subject);
        }
Ejemplo n.º 4
0
        public bool Login(string sPassword)
        {
            FileSystem.IFileSystem fileSystem = m_fileSystemClassFactory.Create(this.User, sPassword);

            if (fileSystem == null)
            {
                return(false);
            }

            SetFileSystemObject(fileSystem);
            return(true);
        }
Ejemplo n.º 5
0
        private RaspberryIRDotNet.RX.IRUnitCounter NewIRUnitCounter(FileSystem.IFileSystem fileSystem)
        {
            var subject = new RaspberryIRDotNet.RX.IRUnitCounter()
            {
                CaptureDevice = LircPath,
                CaptureDelay  = TimeSpan.Zero,
                LeadInPattern = new PulseSpaceUnitList()
                {
                    5, 4
                },
                UnitDurationMicrosecs = 100,
                TargetCaptures        = 5,
                ThrowOnUnknownPacket  = true
            };

            subject.SetFileSystem(fileSystem);
            return(subject);
        }
Ejemplo n.º 6
0
        private RaspberryIRDotNet.RX.LeadInLearner NewLeadInLearner(FileSystem.IFileSystem fileSystem)
        {
            var subject = new RaspberryIRDotNet.RX.LeadInLearner()
            {
                CaptureDevice           = LircPath,
                MinimumMatchingCaptures = 3,
                ThrowOnUnknownPacket    = true
            };

            subject.SetFileSystem(fileSystem);

            var mockDebounce = new Mock <RaspberryIRDotNet.RX.IDebounceTimer>();

            mockDebounce.SetupGet(x => x.ReadyToDoAnother).Returns(true);
            subject.SetDebounceTimer(mockDebounce.Object);

            return(subject);
        }
        private RaspberryIRDotNet.RX.UnitDurationLearner NewUnitDurationLearner(FileSystem.IFileSystem fileSystem)
        {
            var subject = new RaspberryIRDotNet.RX.UnitDurationLearner()
            {
                CaptureDevice          = LircPath,
                CaptureDelay           = TimeSpan.Zero, // Make unit tests run faster
                LeadInPatternDurations = new PulseSpaceDurationList()
                {
                    500, 400
                },
                TargetCaptures       = 3,
                ThrowOnUnknownPacket = true
            };

            subject.SetFileSystem(fileSystem);

            return(subject);
        }
Ejemplo n.º 8
0
        private RaspberryIRDotNet.RX.IRMessageLearn NewIRMessageLearn(FileSystem.IFileSystem fileSystem)
        {
            var subject = new RaspberryIRDotNet.RX.IRMessageLearn()
            {
                CaptureDevice = LircPath,
                CaptureDelay  = TimeSpan.Zero,
                LeadInPattern = new PulseSpaceUnitList()
                {
                    5, 4
                },
                UnitDurationMicrosecs     = 100,
                MessageMinimumUnitCount   = 15,
                MessageMaximumUnitCount   = 15,
                MinimumMatchingCaptures   = 3,
                ErrorAfterBadCaptureCount = 5,
                ThrowOnUnknownPacket      = true
            };

            subject.SetFileSystem(fileSystem);
            return(subject);
        }
Ejemplo n.º 9
0
 /// <summary>
 /// Can be used to abstract away the file system for unit testing.
 /// </summary>
 internal void SetFileSystem(FileSystem.IFileSystem newFS)
 {
     _fileSystem = newFS;
     _utility    = new Utility(newFS);
 }
Ejemplo n.º 10
0
 protected void SetFileSystemObject(FileSystem.IFileSystem fileSystem)
 {
     m_fileSystem = fileSystem;
 }
Ejemplo n.º 11
0
 protected void SetFileSystemObject(FileSystem.IFileSystem fileSystem)
 {
     m_fileSystem = fileSystem;
 }
Ejemplo n.º 12
0
 internal DeviceAssessor(FileSystem.IFileSystem fileSystem)
 {
     _fileSystem = fileSystem;
     _utility    = new Utility(_fileSystem);
 }