[Pkg-mozext-commits] [firebug] 42/68: Manual port of: FBTest for issue 4893

David Prévot taffit at moszumanska.debian.org
Mon Mar 31 22:45:53 UTC 2014


This is an automated email from the git hooks/post-receive script.

taffit pushed a commit to tag fbtest-1.11.4
in repository firebug.

commit bcf9b68f3f3f6d48924aef86a1e6d09b2fc5f608
Author: Jan Odvarko <odvarko at gmail.com>
Date:   Tue Feb 26 10:58:02 2013 +0100

    Manual port of: FBTest for issue 4893
---
 tests/content/css/4893/issue4893.css  |  1 +
 tests/content/css/4893/issue4893.html | 27 ++++++++++++++++++++++++++
 tests/content/css/4893/issue4893.js   | 36 +++++++++++++++++++++++++++++++++++
 tests/content/firebug.html            |  1 +
 4 files changed, 65 insertions(+)

diff --git a/tests/content/css/4893/issue4893.css b/tests/content/css/4893/issue4893.css
new file mode 100644
index 0000000..8218198
--- /dev/null
+++ b/tests/content/css/4893/issue4893.css
@@ -0,0 +1 @@
+body{font-family:Arial,sans-serif;background:#EEE;color:#333;margin:0;padding:0;}
diff --git a/tests/content/css/4893/issue4893.html b/tests/content/css/4893/issue4893.html
new file mode 100644
index 0000000..fc55b73
--- /dev/null
+++ b/tests/content/css/4893/issue4893.html
@@ -0,0 +1,27 @@
+<!DOCTYPE html>
+<html>
+    <head>
+        <title>Issue 4893: CSS panel doesn't display contents of CSS file after reload</title>
+        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
+        <link href="issue4893.css" rel="stylesheet" type="text/css">
+        <link href="../../_common/testcase.css" type="text/css" rel="stylesheet"/>
+    </head>
+    <body>
+        <header>
+            <h1><a href="http://code.google.com/p/fbug/issues/detail?id=4893">Issue 4893</a>:
+                CSS panel doesn't display contents of CSS file after reload</h1>
+        </header>
+        <div>
+            <section id="description">
+                <h3>Steps to reproduce</h3>
+                <ol>
+                    <li>Open Firebug</li>
+                    <li>Switch to the <em>CSS</em> panel</li>
+                    <li>Refresh the page by pressing F5.</li>
+                    <li>Check out CSS panel content. It should display CSS rule for <i>body</i>.</li>
+                </ol>
+            </section>
+            <footer>Jan Odvarko, odvarko at gmail.com</footer>
+        </div>
+    </body>
+</html>
diff --git a/tests/content/css/4893/issue4893.js b/tests/content/css/4893/issue4893.js
new file mode 100644
index 0000000..68f555e
--- /dev/null
+++ b/tests/content/css/4893/issue4893.js
@@ -0,0 +1,36 @@
+function runTest()
+{
+    FBTest.sysout("issue4893.START");
+    FBTest.openNewTab(basePath + "css/4893/issue4893.html", function(win)
+    {
+        FBTest.openFirebug();
+        FBTest.selectPanel("stylesheet");
+
+        // Catch the first page load and Style panel update.
+        waitForCssRules(function()
+        {
+            // Reload the page.
+            FBTest.reload(function()
+            {
+                // Catch the second style update
+                waitForCssRules(function()
+                {
+                    FBTest.testDone("issue4893.DONE");
+                });
+            });
+        });
+    });
+}
+
+function waitForCssRules(callback)
+{
+    var config = {tagName: "div", classes: "cssEditableRule"};
+    FBTest.waitForDisplayedElement("stylesheet", config, function(row)
+    {
+        var panel = FBTest.selectSidePanel("stylesheet");
+        var nodes = panel.panelNode.querySelectorAll(".cssEditableRule");
+        FBTest.compare(1, nodes.length, "There must be one style");
+
+        callback();
+    });
+}
diff --git a/tests/content/firebug.html b/tests/content/firebug.html
index 27362cd..c4c6041 100644
--- a/tests/content/firebug.html
+++ b/tests/content/firebug.html
@@ -239,6 +239,7 @@ var testList = [
     {group: "css",                uri: "css/5644/issue5644.js",                   desc: "Editing a disabled property makes another", testPage: "css/5644/issue5644.html"},
     {group: "css",                uri: "css/6281/issue6281.js",                   desc: "Placeholder rules are no longer displayed in HTML Style tab.", testPage: "css/6281/issue6281.html"},
     {group: "css",                uri: "css/6282/issue6282.js",                   desc: "CSS panel fails on interpreting @page", testPage: "css/6282/issue6282.html"},
+    {group: "css",                uri: "css/4893/issue4893.js",                   desc: "   CSS panel doesn't display contents of CSS file after reload", testPage: "css/4893/issue4893.html"},
     {group: "css/computed",       uri: "css/computed/3207/issue3207.js",          desc: "CSS properties in the \"Computed\" tab are not updated correctly", testPage: "css/computed/3207/issue3207.html"},
     {group: "css/computed",       uri: "css/computed/4132/issue4132.js",          desc: "Only show applied styles in Computed side panel", testPage: "css/computed/4132/issue4132.html"},
     {group: "css/computed",       uri: "css/computed/5449/issue5449.js",          desc: "Show infotips in Computed side panel", testPage: "css/computed/5449/issue5449.html"},

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-mozext/firebug.git



More information about the Pkg-mozext-commits mailing list