Skip to content

Commit

Permalink
Merge pull request #1 from tombatchelor/master
Browse files Browse the repository at this point in the history
Resolved issue getting TFS2015 CI
  • Loading branch information
droberts2013 committed Dec 18, 2015
2 parents 4f3ef66 + 4976182 commit e9b842f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ This plugin offers an interface from XL Release to Team Foundation Server via th

The functionality will be enriched with additional Work Item fields as specific needs materialize.

Note: HttpRequest.py in older versions of XL Release must be enhanced to support the HTTP PATCH method. See https://github.com/droberts2013/xl-release/server/src/main/resources/pythonutil/HttpRequest.py if necessary. Place this custom file in <xl-release-server>/ext/pythonutil.
Note: HttpRequest.py in older versions of XL Release must be enhanced to support the HTTP PATCH method. See [droberts2013/xl-release/server/src/main/resources/pythonutil/HttpRequest.py](https://github.com/droberts2013/xl-release/blob/afc1468c9fde54d03f046211fbc1b9e1068106c1/server/src/main/resources/pythonutil/HttpRequest.py) if necessary. Place this custom file in <xl-release-server>/ext/pythonutil.

## TFS SDK

Expand Down
6 changes: 3 additions & 3 deletions src/main/resources/tfsrest/CreateWorkItem.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,15 +9,15 @@

print "Executing CreateWorkItem.py ver 2015Jun28-1"

if tfs2015Server is None:
if tfsServer is None:
print "No server provided"
sys.exit(1)

contentType = 'application/json-patch+json'

request = HttpRequest(tfs2015Server)
request = HttpRequest(tfsServer)
content = '[{"path": "/fields/System.Title", "value": "%s", "op": "add"}]' % workItemTitle
response = request.patch('%s/%s/_apis/wit/workitems/$%s?api-version=1.0' % (collection, teamProject, workItemType), content, contentType=contentType)
response = request.patch('tfs/%s/%s/_apis/wit/workitems/$%s?api-version=1.0' % (collectionName, teamProjectName, workItemType), content, contentType=contentType)
httpStatusCode = response.status
print httpStatusCode
print response.response
Expand Down

0 comments on commit e9b842f

Please sign in to comment.