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 199565 Details for
Bug 347776
[client] Unstaging selected file causes error
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.
Test that used to fail.
testResetChangedWithFolderPath.txt (text/plain), 3.27 KB, created by
Tomasz Zarna
on 2011-07-13 06:56:03 EDT
(
hide
)
Description:
Test that used to fail.
Filename:
MIME Type:
Creator:
Tomasz Zarna
Created:
2011-07-13 06:56:03 EDT
Size:
3.27 KB
patch
obsolete
>@Test > public void testResetChangedWithFolderPath() throws Exception { > // see bug 348524 > URI workspaceLocation = createWorkspace(getMethodName()); > > String projectName = getMethodName(); > JSONObject project = createProjectOrLink(workspaceLocation, projectName, gitDir.toString()); > String projectId = project.getString(ProtocolConstants.KEY_ID); > > // TODO: don't create URIs out of thin air > WebRequest request = getPutFileRequest(projectId + "/folder/folder.txt", "hello"); > WebResponse response = webConversation.getResponse(request); > assertEquals(HttpURLConnection.HTTP_OK, response.getResponseCode()); > > JSONObject gitSection = project.getJSONObject(GitConstants.KEY_GIT); > String gitIndexUri = gitSection.getString(GitConstants.KEY_INDEX); > String gitStatusUri = gitSection.getString(GitConstants.KEY_STATUS); > > // TODO: don't create URIs out of thin air > request = GitAddTest.getPutGitIndexRequest(gitIndexUri + "folder/folder.txt"); > response = webConversation.getResponse(request); > assertEquals(HttpURLConnection.HTTP_OK, response.getResponseCode()); > > request = GitStatusTest.getGetGitStatusRequest(gitStatusUri); > response = webConversation.getResponse(request); > assertEquals(HttpURLConnection.HTTP_OK, response.getResponseCode()); > JSONObject statusResponse = new JSONObject(response.getText()); > JSONArray statusArray = statusResponse.getJSONArray(GitConstants.KEY_STATUS_ADDED); > assertEquals(0, statusArray.length()); > statusArray = statusResponse.getJSONArray(GitConstants.KEY_STATUS_CHANGED); > assertEquals(1, statusArray.length()); > statusArray = statusResponse.getJSONArray(GitConstants.KEY_STATUS_MISSING); > assertEquals(0, statusArray.length()); > statusArray = statusResponse.getJSONArray(GitConstants.KEY_STATUS_MODIFIED); > assertEquals(0, statusArray.length()); > statusArray = statusResponse.getJSONArray(GitConstants.KEY_STATUS_REMOVED); > assertEquals(0, statusArray.length()); > statusArray = statusResponse.getJSONArray(GitConstants.KEY_STATUS_UNTRACKED); > assertEquals(0, statusArray.length()); > > // TODO: don't create URIs out of thin air > request = getPostGitIndexRequest(gitIndexUri, new String[] {"folder/folder.txt"}, null, (String) null); > response = webConversation.getResponse(request); > assertEquals(HttpURLConnection.HTTP_OK, response.getResponseCode()); > > request = GitStatusTest.getGetGitStatusRequest(gitStatusUri); > response = webConversation.getResponse(request); > assertEquals(HttpURLConnection.HTTP_OK, response.getResponseCode()); > statusResponse = new JSONObject(response.getText()); > statusArray = statusResponse.getJSONArray(GitConstants.KEY_STATUS_ADDED); > assertEquals(0, statusArray.length()); > statusArray = statusResponse.getJSONArray(GitConstants.KEY_STATUS_CHANGED); > assertEquals(0, statusArray.length()); > statusArray = statusResponse.getJSONArray(GitConstants.KEY_STATUS_MISSING); > assertEquals(0, statusArray.length()); > statusArray = statusResponse.getJSONArray(GitConstants.KEY_STATUS_MODIFIED); > assertEquals(1, statusArray.length()); > statusArray = statusResponse.getJSONArray(GitConstants.KEY_STATUS_REMOVED); > assertEquals(0, statusArray.length()); > statusArray = statusResponse.getJSONArray(GitConstants.KEY_STATUS_UNTRACKED); > assertEquals(0, statusArray.length()); > }
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 Raw
Actions:
View
Attachments on
bug 347776
: 199565 |
199566