public void TestEbookDocxEpub3()
        {
            RabbitMQCluster.ClusterConnect();
            var testDocumentsName = "A1.Daisy.docx";
            var apiFileContent    = inputFiles.Where(x => x.Key.EndsWith(testDocumentsName)).Select(x => x.Value).First();
            var ebookj            = new DaisyJob()
            {
                Id              = Guid.NewGuid(),
                FileContent     = apiFileContent,
                UserId          = Guid.Parse("d2b97532-e8c5-e411-8270-f0def103cfd0"),
                FileExtension   = ".docx",
                FileName        = "testDaisyEPUB3WMO",
                MimeType        = "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
                Status          = JobStatus.Started,
                SubmitTime      = DateTime.Now,
                DownloadCounter = 0,
                InputFileHash   = RoboBrailleProcessor.GetMD5Hash(apiFileContent),
                DaisyOutput     = DaisyOutput.Epub3WMO
            };

            var apiTask = Task.Run(() => WebAPICall(ebookj));

            byte[] apiRes = apiTask.Result;

            //assert
            NUnit.Framework.Assert.IsNotEmpty(apiRes);
            IOController.SaveTestResultFile(apiRes, "Ebook-" + timestamp + "-EPUB3WMO-API.epub");

            RabbitMQCluster.ClusterDisconnect();
        }
        public void Cleanup()
        {
            //dissconnect from rabbitmq or close audio agent test instance

            /* through cmd connect
             * Step 1) rabbitmqctl stop_app
             * Step 2) rabbitmqctl reset
             * Step 3) rabbitmqctl start_app
             */
            RabbitMQCluster.ClusterDisconnect();
        }
        public void Initialize()
        {
            //connect with rabbitmq (must be on the same local network as the audio agents) and rabbitmqctl must be on path

            /* through cmd connect
             * Step 1) rabbitmqctl stop_app
             * Step 2) rabbitmqctl join_cluster robobraille
             * Step 3) rabbitmqctl start_app
             */
            RabbitMQCluster.ClusterConnect();
        }
Exemple #4
0
 public void Cleanup()
 {
     RabbitMQCluster.ClusterDisconnect();
 }
Exemple #5
0
 public void Initialize()
 {
     inputFiles = IOController.GetInputFiles();
     RabbitMQCluster.ClusterConnect();
 }