mingle-macro-development-toolkit 1.1 → 1.2
Sign up to get free protection for your applications and to get access to all the features.
- data/History.txt +12 -1
- data/README.rdoc +1 -1
- data/example/macro.rb +1 -1
- data/getting_started.txt +12 -8
- data/lib/macro_development_toolkit.rb +1 -1
- data/lib/macro_development_toolkit/mingle/project.rb +5 -3
- data/test/fixtures/sample/project_variables.yml +3 -2
- data/test/integration/rest_loader_test.rb +2 -2
- metadata +3 -3
data/History.txt
CHANGED
@@ -1,4 +1,15 @@
|
|
1
|
+
== 1.2 April 16, 2009
|
2
|
+
|
3
|
+
* Mingle 2.3 integration
|
4
|
+
* Ability to emit Javascript from a macro
|
5
|
+
* Fixed RDoc documentation
|
6
|
+
|
1
7
|
== 1.1 April 8, 2009
|
2
8
|
|
3
|
-
* 1 bug fix
|
9
|
+
* 1 bug fix
|
4
10
|
* Fix project variable value to return the display value. In response to post http://community.thoughtworks.com/posts/462f0f399b
|
11
|
+
* Added documentation
|
12
|
+
|
13
|
+
== 1.0 August 1, 2008
|
14
|
+
|
15
|
+
* Initial release
|
data/README.rdoc
CHANGED
@@ -38,7 +38,7 @@ of fleshing out your macro.
|
|
38
38
|
|
39
39
|
== SUPPORT:
|
40
40
|
|
41
|
-
For any issues/clarifications/comments with installation or using this gem, contact us at the Mingle forums[http://
|
41
|
+
For any issues/clarifications/comments with installation or using this gem, contact us at the Mingle forums[http://community.thoughtworks.com/pages/home]. You can also get in touch with the ThoughtWorks Studios support
|
42
42
|
team over email at support@thoughtworks.com
|
43
43
|
|
44
44
|
== LICENSE:
|
data/example/macro.rb
CHANGED
data/getting_started.txt
CHANGED
@@ -53,7 +53,7 @@ All data that is required to execute the macro is injected into the macro throug
|
|
53
53
|
|
54
54
|
The execute method uses the MQL execution facility that the project class provides, to execute the MQL string that is passed into through the parameters hash. It then formats the results to be a number, and provides that result of the execute command.
|
55
55
|
|
56
|
-
For more help on what constitutes valid MQL, you can refer to our help documentation at http://studios.thoughtworks.com/mingle-agile-project-management/2.
|
56
|
+
For more help on what constitutes valid MQL, you can refer to our help documentation at http://studios.thoughtworks.com/mingle-agile-project-management/2.3/help/mql_reference.html
|
57
57
|
|
58
58
|
Writing your own macro
|
59
59
|
----------------------
|
@@ -125,8 +125,11 @@ class WorkGauge
|
|
125
125
|
|
126
126
|
end
|
127
127
|
|
128
|
-
|
129
|
-
|
128
|
+
The execute method can return any valid HTML or Javascript content. The ability to emit Javascript content, specifically, can only be used on Mingle version 2.3 and above.
|
129
|
+
|
130
|
+
The following example demonstrates how to use the Javascript emission functionality to embed a Google Maps map.
|
131
|
+
|
132
|
+
Note: For this example to work, you will have to supply your own Google Maps API key as a part of the script tag that loads the Google API.
|
130
133
|
|
131
134
|
class GoogleMap
|
132
135
|
|
@@ -161,7 +164,7 @@ class GoogleMap
|
|
161
164
|
end
|
162
165
|
|
163
166
|
Long running or integration macros which run on server will result in long page render times. We recommend these sort
|
164
|
-
of macros use
|
167
|
+
of macros use Javascript (or JSONP) to offload work to the browser.
|
165
168
|
|
166
169
|
You can find both simpler and more complex examples in the vendor/plugins/sample_macros directory.
|
167
170
|
|
@@ -201,7 +204,7 @@ Integration testing your macro
|
|
201
204
|
|
202
205
|
########################################################NOTE###############################################################
|
203
206
|
# #
|
204
|
-
# IN ORDER TO RUN THE INTEGRATION TESTS, YOU WILL NEED TO TURN ON BASIC AUTHENTICATION FOR THE MINGLE 2.
|
207
|
+
# IN ORDER TO RUN THE INTEGRATION TESTS, YOU WILL NEED TO TURN ON BASIC AUTHENTICATION FOR THE MINGLE 2.3 SERVER THAT YOU #
|
205
208
|
# ARE GOING TO BE TESTING AGAINST. #
|
206
209
|
# #
|
207
210
|
#########################################################NOTE##############################################################
|
@@ -232,7 +235,7 @@ end
|
|
232
235
|
|
233
236
|
The skeleton project also has a sample integration test set up for you, which points to a bogus Mingle server, and uses bad credentials. Replace this resource URL with the URL for a deployed instance within your organization. The helper method project(...) which takes the resource URL, loads the data from the XML data obtained from the live instance of Mingle.
|
234
237
|
|
235
|
-
You can see examples of integration tests in the average macro that is packaged with Mingle in the vendor/plugins/average_macro directory. These tests run against a standard template that ships with Mingle2.
|
238
|
+
You can see examples of integration tests in the average macro that is packaged with Mingle in the vendor/plugins/average_macro directory. These tests run against a standard template that ships with Mingle2.3, and so you should be able to run them within your organization too, without a problem.
|
236
239
|
|
237
240
|
To run your integration tests, run
|
238
241
|
|
@@ -254,6 +257,7 @@ Deploying your macro
|
|
254
257
|
# DATA THAT PEOPLE WOULD NORMALLY NOT BE AUTHORIZED TO SEE #
|
255
258
|
# * LENGTHY CALLS TO EXTERNAL SYSTEMS COULD TIE UP MINGLE RESOURCES AND LEAVE THE APP UNRESPONSIVE #
|
256
259
|
# * SYSTEM CALLS, IF USED, MUST BE INSPECTED AND WELL-UNDERSTOOD PRIOR TO DEPLOYMENT #
|
260
|
+
# * IF THE MACRO EMITS BAD JAVASCRIPT, YOU COULD BREAK BASIC FUNCTIONALITY ON THE MINGLE UI #
|
257
261
|
# * OTHER DATABASE ACTIVITY, SUCH AS TRANSACTION COMMITS, SHOULD BE MONITORED AND AVOIDED #
|
258
262
|
# #
|
259
263
|
######################################################## CAUTION ##########################################################
|
@@ -263,7 +267,7 @@ To deploy your macro to a locally deployed instance of Mingle, which is running
|
|
263
267
|
|
264
268
|
% rake macro:deploy MINGLE_LOCATION=/path/to/mingle_root
|
265
269
|
|
266
|
-
where /path/to/mingle_root is the location where Mingle2.
|
270
|
+
where /path/to/mingle_root is the location where Mingle2.3 is installed.
|
267
271
|
|
268
272
|
* On Windows, this is the location that the installer installed Mingle at
|
269
273
|
* On OSX, this will be within the app bundle, at <mingle_application_bundle>/Contents/Resources/app
|
@@ -279,7 +283,7 @@ Alternatively, you could also copy the folder by hand into the same location.
|
|
279
283
|
# #
|
280
284
|
#########################################################NOTE###############################################################
|
281
285
|
|
282
|
-
This Getting Started file and the mingle-macro-development-toolkit-1.
|
286
|
+
This Getting Started file and the mingle-macro-development-toolkit-1.2.gem are owned exclusively by ThoughtWorks, Inc.,
|
283
287
|
and ThoughtWorks reserves all rights therein.
|
284
288
|
|
285
289
|
We believe that it is a sound practice from legal, business and software development perspectives to always provide copyright
|
@@ -43,9 +43,11 @@ module Mingle
|
|
43
43
|
end
|
44
44
|
|
45
45
|
# *accepts*: A valid MQL string. To see what constitutes valid MQL,
|
46
|
-
# look here[http://studios.thoughtworks.com/mingle-agile-project-management/2.
|
46
|
+
# look here[http://studios.thoughtworks.com/mingle-agile-project-management/2.3/help/index.html]
|
47
47
|
#
|
48
|
-
# *returns*:
|
48
|
+
# *returns*: An Array of Hashes, in which each Hash represents one row of results from the MQL execution
|
49
|
+
# The keys in the Hash are the names of the properties selected, with spaces and special characters replaced
|
50
|
+
# with underscores(_).
|
49
51
|
def execute_mql(mql)
|
50
52
|
CardQuery.parse(mql, @card_query_options).values
|
51
53
|
end
|
@@ -57,7 +59,7 @@ module Mingle
|
|
57
59
|
# cached.
|
58
60
|
#
|
59
61
|
# *accepts*: A valid MQL string. To see what constitutes valid MQL,
|
60
|
-
# look here[http://studios.thoughtworks.com/mingle-agile-project-management/2.
|
62
|
+
# look here[http://studios.thoughtworks.com/mingle-agile-project-management/2.3/help/index.html]
|
61
63
|
#
|
62
64
|
# *returns*: A boolean indicating whether the data pertaining to the MQL can be cached
|
63
65
|
def can_be_cached?(mql)
|
@@ -4,11 +4,11 @@ require File.dirname(__FILE__) + '/integration_test_helper.rb'
|
|
4
4
|
|
5
5
|
class RestLoaderTest < Test::Unit::TestCase
|
6
6
|
|
7
|
-
TEST_PROJECT = 'http://bjanakir:p@localhost:8080/lightweight_projects/
|
7
|
+
TEST_PROJECT = 'http://bjanakir:p@localhost:8080/lightweight_projects/scrum_template_2_3.xml'
|
8
8
|
|
9
9
|
def test_should_load_direct_project_attributes_from_correct_fixture
|
10
10
|
assert_not_nil project(TEST_PROJECT)
|
11
|
-
assert_equal '
|
11
|
+
assert_equal 'scrum_template_2_3', project(TEST_PROJECT).identifier
|
12
12
|
end
|
13
13
|
|
14
14
|
def test_should_load_first_level_project_associations_from_correct_fixture
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mingle-macro-development-toolkit
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: "1.
|
4
|
+
version: "1.2"
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- ThoughtWorks Inc
|
@@ -9,7 +9,7 @@ autorequire:
|
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
11
|
|
12
|
-
date: 2009-04-
|
12
|
+
date: 2009-04-16 00:00:00 -07:00
|
13
13
|
default_executable:
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
@@ -104,7 +104,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
104
104
|
requirements: []
|
105
105
|
|
106
106
|
rubyforge_project: mingle-macros
|
107
|
-
rubygems_version: 1.3.
|
107
|
+
rubygems_version: 1.3.0
|
108
108
|
signing_key:
|
109
109
|
specification_version: 2
|
110
110
|
summary: ""
|