Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 86767 Details for
Bug 189695
move stripping of RSS induced tags into core
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read
this important communication.
[patch]
test case showing problem with last changes
clipboard.txt (text/plain), 6.72 KB, created by
Eugene Kuleshov
on 2008-01-12 20:35:10 EST
(
hide
)
Description:
test case showing problem with last changes
Filename:
MIME Type:
Creator:
Eugene Kuleshov
Created:
2008-01-12 20:35:10 EST
Size:
6.72 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.mylyn.jira.core >Index: src/org/eclipse/mylyn/internal/jira/core/service/web/rss/RssReader.java >=================================================================== >RCS file: /cvsroot/tools/org.eclipse.mylyn/org.eclipse.mylyn.jira.core/src/org/eclipse/mylyn/internal/jira/core/service/web/rss/RssReader.java,v >retrieving revision 1.12 >diff -u -r1.12 RssReader.java >--- src/org/eclipse/mylyn/internal/jira/core/service/web/rss/RssReader.java 18 Sep 2007 19:08:13 -0000 1.12 >+++ src/org/eclipse/mylyn/internal/jira/core/service/web/rss/RssReader.java 13 Jan 2008 01:29:52 -0000 >@@ -25,7 +25,7 @@ > * @author Brock Janiczak > * @author Steffen Pingel > */ >-class RssReader { >+public class RssReader { > > private final JiraClient server; > >#P org.eclipse.mylyn.jira.tests >Index: src/org/eclipse/mylyn/jira/tests/RssReaderTest.java >=================================================================== >RCS file: src/org/eclipse/mylyn/jira/tests/RssReaderTest.java >diff -N src/org/eclipse/mylyn/jira/tests/RssReaderTest.java >--- /dev/null 1 Jan 1970 00:00:00 -0000 >+++ src/org/eclipse/mylyn/jira/tests/RssReaderTest.java 1 Jan 1970 00:00:00 -0000 >@@ -0,0 +1,65 @@ >+/******************************************************************************* >+ * Copyright (c) 2004, 2007 Mylyn project committers and others. >+ * All rights reserved. This program and the accompanying materials >+ * are made available under the terms of the Eclipse Public License v1.0 >+ * which accompanies this distribution, and is available at >+ * http://www.eclipse.org/legal/epl-v10.html >+ *******************************************************************************/ >+ >+package org.eclipse.mylyn.jira.tests; >+ >+import java.io.InputStream; >+ >+import junit.framework.TestCase; >+ >+import org.eclipse.mylyn.internal.jira.core.model.Issue; >+import org.eclipse.mylyn.internal.jira.core.model.ServerInfo; >+import org.eclipse.mylyn.internal.jira.core.service.JiraClient; >+import org.eclipse.mylyn.internal.jira.core.service.JiraException; >+import org.eclipse.mylyn.internal.jira.core.service.web.rss.RssReader; >+ >+/** >+ * @author Eugene Kuleshov >+ */ >+public class RssReaderTest extends TestCase { >+ >+ public void testRssReader() throws Exception { >+ String baseUrl = "http://foo"; >+ >+ JiraClient client = new MockJiraClient(baseUrl) { >+ public ServerInfo getServerInfo() throws JiraException { >+ ServerInfo serverInfo = new ServerInfo(); >+ return serverInfo; >+ } >+ }; >+ >+ MockIssueCollector collector = new MockIssueCollector(); >+ RssReader reader = new RssReader(client, collector); >+ >+ InputStream is = getClass().getResourceAsStream("rssWithMarkup.xml"); >+ reader.readRssFeed(is, baseUrl); >+ >+ Issue issue = collector.issues.get(0); >+ >+ String description = issue.getDescription(); >+ >+ // expected description is cut from rss xml with html entities converted >+ assertEquals("Testing common markup\n" + >+ "\n" + >+ "<p>New paragraph</p>\n" + >+ "\n" + >+ "<ul>\n" + >+ " <li>item 1</li>\n" + >+ " <li>item 2</li>\n" + >+ " <li>item 3</li>\n" + >+ "</ul>\n" + >+ "\n" + >+ "\n" + >+ "<div class=\"preformatted\"><div class=\"preformattedContent\">\n" + >+ "<pre>+- root\n" + >+ " +- child 1\n" + >+ " +- child 2\n" + >+ "</pre>\n" + >+ "</div></div>", description); >+ } >+} >Index: src/org/eclipse/mylyn/jira/tests/rssWithMarkup.xml >=================================================================== >RCS file: src/org/eclipse/mylyn/jira/tests/rssWithMarkup.xml >diff -N src/org/eclipse/mylyn/jira/tests/rssWithMarkup.xml >--- /dev/null 1 Jan 1970 00:00:00 -0000 >+++ src/org/eclipse/mylyn/jira/tests/rssWithMarkup.xml 1 Jan 1970 00:00:00 -0000 >@@ -0,0 +1,81 @@ >+<!-- RSS generated by JIRA (Enterprise Edition, Version: 3.11-#288) at Sat Jan 12 19:15:07 CST 2008 --> >+<rss version="0.92" > >+<channel> >+ <title>jira.codehaus.org</title> >+ <link>http://jira.codehaus.org</link> >+ <description>This file is an XML representation of an issue</description> >+ <language>en-uk</language> >+<item> >+<title>[MNGECLIPSE-463] test</title> >+<link>http://jira.codehaus.org/browse/MNGECLIPSE-463</link> >+ >+ <description>Testing common markup >+ >+<p>New paragraph</p> >+ >+<ul> >+ <li>item 1</li> >+ <li>item 2</li> >+ <li>item 3</li> >+</ul> >+ >+ >+<div class="preformatted"><div class="preformattedContent"> >+<pre>+- root >+ +- child 1 >+ +- child 2 >+</pre> >+</div></div></description> >+ <environment></environment> >+ <key id="61471">MNGECLIPSE-463</key> >+ <summary>test</summary> >+ <type id="3" iconUrl="http://jira.codehaus.org/images/icons/task.gif">Task</type> >+ >+ <priority id="3" iconUrl="http://jira.codehaus.org/images/icons/priority_major.gif">Major</priority> >+ <status id="1" iconUrl="http://jira.codehaus.org/images/icons/status_open.gif">Open</status> >+ <resolution id="-1">Unresolved</resolution> >+ >+ >+ <assignee username="-1">Unassigned</assignee> >+ >+ <reporter username="eu">Eugene Kuleshov</reporter> >+ >+ <created>Sat, 12 Jan 2008 19:14:42 -0600 (CST)</created> >+ <updated>Sat, 12 Jan 2008 19:14:42 -0600 (CST)</updated> >+ >+ >+ >+ >+ <due></due> >+ >+ <votes>0</votes> >+ >+ >+ >+ >+ <attachments> >+ </attachments> >+ >+ <subtasks> >+ </subtasks> >+ >+ <customfields> >+ <customfield id="customfield_10163" key="com.atlassian.jira.toolkit:dayslastcommented"> >+ <customfieldname>Days since last comment</customfieldname> >+ <customfieldvalues> >+ Less than a minute ago >+ >+ </customfieldvalues> >+ </customfield> >+ <customfield id="customfield_10161" key="com.atlassian.jira.toolkit:participants"> >+ <customfieldname>Participants</customfieldname> >+ <customfieldvalues> >+ <customfieldvalue>eu</customfieldvalue> >+ >+ </customfieldvalues> >+ </customfield> >+ </customfields> >+ >+</item> >+</channel> >+</rss>
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 189695
:
86744
| 86767