Beispiel #1
0
        public static ALMResponseData CreateAttachment(ResourceType resourceType, string id, string zipFileName)
        {
            FileStream   fs = new FileStream(zipFileName, FileMode.Open, FileAccess.Read);
            BinaryReader br = new BinaryReader(fs);

            byte[]          fileData = br.ReadBytes((Int32)fs.Length);
            ALMResponseData response = QcRestClient.CreateAttachmentForEntitiyId(ResourceType.TEST_RUN, id, zipFileName.Split(Path.DirectorySeparatorChar).Last(), fileData);

            fs.Close();
            return(response);
        }