Exemplo n.º 1
0
        public void Query_ArchivingDisabledGloballyDisabledOnQuery_DoesNotArchives()
        {
            PerfionClientImpl subject = CreateSubject();

            _proxy.ExecuteQuery(Arg.Any <ExecuteQueryRequest>()).Returns(_executeQueryResponse);

            subject.Query("<query/>", options => options.Disable());

            _archiveService.DidNotReceive().Create(Arg.Any <string>(), Arg.Any <Action <ArchiveCreated> >());
        }
Exemplo n.º 2
0
        public void Query_ArchivingEnabledGloballyEnabledOnQuery_ArchivesLocal()
        {
            PerfionClientImpl subject = CreateSubject(new ArchiveOptions("Global"));

            _proxy.ExecuteQuery(Arg.Any <ExecuteQueryRequest>()).Returns(_executeQueryResponse);

            subject.Query("<query/>", options => options.Named("Local"));

            _archiveService.Received().Create(Arg.Is("Local"), Arg.Any <Action <ArchiveCreated> >());
        }