2 new revisions:
Revision: 8cb0ef760263
Author: Mikko Korpela <[email protected]>
Date: Mon Jan 30 06:20:07 2012
Log: log.html: Expand all working
http://code.google.com/p/robotframework/source/detail?r=8cb0ef760263
Revision: 7d2bde8c91ad
Author: Mikko Korpela <[email protected]>
Date: Mon Jan 30 06:20:18 2012
Log: Automated merge with https://code.google.com/p/robotframework/
http://code.google.com/p/robotframework/source/detail?r=7d2bde8c91ad
==============================================================================
Revision: 8cb0ef760263
Author: Mikko Korpela <[email protected]>
Date: Mon Jan 30 06:20:07 2012
Log: log.html: Expand all working
http://code.google.com/p/robotframework/source/detail?r=8cb0ef760263
Modified:
/src/robot/webcontent/log.js
/src/robot/webcontent/model.js
/utest/webcontent/spec/ParsingSpec.js
=======================================
--- /src/robot/webcontent/log.js Mon Jan 30 05:20:51 2012
+++ /src/robot/webcontent/log.js Mon Jan 30 06:20:07 2012
@@ -17,15 +17,19 @@
}
function toggleElement(elementId, childrenNames) {
- var foldingButton = $('#'+elementId+'_foldingbutton');
var childElement = $("#"+elementId+"_children");
childElement.toggle(100);
+ populateChildren(elementId, childElement, childrenNames);
+ var foldingButton = $('#'+elementId+'_foldingbutton');
+ foldingButton.text(foldingButton.text() == '+' ? '-' : '+');
+}
+
+function populateChildren(elementId, childElement, childrenNames) {
if (!childElement.hasClass("populated")) {
var element = window.testdata.find(elementId);
element.callWhenChildrenReady(drawCallback(element, childElement,
childrenNames));
childElement.addClass("populated");
}
- foldingButton.text(foldingButton.text() == '+' ? '-' : '+');
}
function drawCallback(element, childElement, childrenNames) {
@@ -57,9 +61,10 @@
}
function expandElement(element) {
- if (!$("#" + element.id + "_children").is(":visible")) {
- $("#" + element.id + " .elementheader").click();
- }
+ var childElement = $("#" + element.id + "_children");
+ childElement.show(100);
+ populateChildren(element.id, childElement, element.childrenNames);
+ $('#'+element.id+'_foldingbutton').text('-');
}
function elementHiddenByUser(elementId) {
=======================================
--- /src/robot/webcontent/model.js Tue Nov 29 01:34:38 2011
+++ /src/robot/webcontent/model.js Mon Jan 30 06:20:07 2012
@@ -10,6 +10,7 @@
suite.populateKeywords = createIterablePopulator("Keyword");
suite.populateTests = createIterablePopulator("Test");
suite.populateSuites = createIterablePopulator("Suite");
+ suite.childrenNames = ['keyword', 'suite', 'test'];
suite.message = data.message;
suite.children = function () {
return
suite.keywords().concat(suite.tests()).concat(suite.suites());
@@ -105,6 +106,7 @@
test.formatParentName = function () { return
util.formatParentName(test); };
test.timeout = data.timeout;
test.populateKeywords = createIterablePopulator("Keyword");
+ test.childrenNames = ['keyword'];
test.isChildrenLoaded = data.isChildrenLoaded;
test.callWhenChildrenReady =
window.fileLoading.getCallbackHandlerForKeywords(test);
test.children = function () {
@@ -127,6 +129,7 @@
kw.timeout = data.timeout;
kw.populateMessages = createIterablePopulator("Message");
kw.populateKeywords = createIterablePopulator("Keyword");
+ kw.childrenNames = ['keyword', 'message'];
kw.isChildrenLoaded = data.isChildrenLoaded;
kw.callWhenChildrenReady =
window.fileLoading.getCallbackHandlerForKeywords(kw);
kw.children = function () {
=======================================
--- /utest/webcontent/spec/ParsingSpec.js Wed Nov 9 05:29:15 2011
+++ /utest/webcontent/spec/ParsingSpec.js Mon Jan 30 06:20:07 2012
@@ -86,6 +86,7 @@
expect(suite.times.elapsedMillis).toBeLessThan(1000);
expectStats(suite, 1, 1, 1, 1);
expect(suite.metadata[0]).toEqual(["meta", "data"]);
+ expect(suite.childrenNames).toEqual(['keyword', 'suite', 'test']);
});
it("should parse test", function () {
@@ -99,6 +100,7 @@
expect(test.times.elapsedMillis).toBeGreaterThan(0);
expect(test.times.elapsedMillis).toBeLessThan(window.testdata.suite().times.elapsedMillis+1);
expect(test.timeout).toEqual("1 second");
+ expect(test.childrenNames).toEqual(['keyword']);
});
it("should parse keyword", function () {
@@ -110,6 +112,7 @@
expect(kw.times.elapsedMillis).toBeLessThan(200);
expect(kw.path).toEqual("Suite.Test.0");
expect(kw.type).toEqual("KEYWORD");
+ expect(kw.childrenNames).toEqual(['keyword', 'message'])
});
it("should parse for loop", function() {
==============================================================================
Revision: 7d2bde8c91ad
Author: Mikko Korpela <[email protected]>
Date: Mon Jan 30 06:20:18 2012
Log: Automated merge with https://code.google.com/p/robotframework/
http://code.google.com/p/robotframework/source/detail?r=7d2bde8c91ad