Beispiel #1
0
 private static void writeOutTaskDetails(WorkItemParser wip)
 {
     Console.WriteLine("Activity      :" + wip.WorkItem.Fields["Activity"].Value);
     Console.WriteLine("Remaining Work:" + wip.WorkItem.Fields["Remaining Work"].Value);
     if (wip.Description != null && wip.Description.Length > 0)
     {
         Console.WriteLine("Description   :");
         Console.WriteLine(wip.Description);
     }
 }
Beispiel #2
0
        private static void writeOutDescriptionAndAcceptanceCriteria(WorkItemParser wip)
        {
            if (options.ShowSummary)
            {
                return;             //Drop out if the user only wants to see the summary
            }

            Console.ForegroundColor = descriptionColour;

            string desc = wip.Description;

            var maxLen = (desc.Length - 1 > maxOutputLength ? maxOutputLength : desc.Length);

            if (options.ShowAllText)
            {
                maxLen = desc.Length;
            }

            if (maxLen > 0)
            {
                Console.WriteLine(descriptionSeparator);
                Console.WriteLine(desc.Substring(0, maxLen));
            }
            else
            {
                Console.WriteLine("Description   :<empty>");
            }


            Console.ForegroundColor = acceptanceColour;

            string acceptance = wip.AcceptanceCriteria;

            maxLen = (acceptance.Length - 1 > maxOutputLength ? maxOutputLength : acceptance.Length);

            if (options.ShowAllText)
            {
                maxLen = acceptance.Length;
            }

            if (maxLen > 0)
            {
                Console.WriteLine(AcceptanceSeparator);
                Console.WriteLine(acceptance.Substring(0, maxLen));
            }
            else
            {
                Console.WriteLine("Accp Criteria :<empty>");
            }
        }