-
Notifications
You must be signed in to change notification settings - Fork 343
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into issue5585
- Loading branch information
Showing
6 changed files
with
150 additions
and
67 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -0,0 +1,68 @@ | |||
<!DOCTYPE html> | |||
<html> | |||
<!-- | |||
STEPS TO CREATE A TEST CASE: | |||
1. Replace "xxxx" by number of your issue | |||
2. Replace "Issue summary" by title of your issue | |||
3. Put inspectable elements, form fields etc. into the "content" section | |||
4. Add the exact steps to reproduce your issue under "Steps to reproduce" | |||
5. Describe the currently seen result under "Observed result" | |||
6. Describe what you would expect to see under "Expected result" | |||
7. Add your contact information | |||
8. Remove all template comments | |||
Note: Make sure, the URL to testcase.css is https://getfirebug.com/tests/content/templates/default/testcase.css | |||
--> | |||
<head> | |||
<!-- | |||
Add the issue number and title here. | |||
--> | |||
<title>Issue xxxx: Issue summary</title> | |||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> | |||
<link href="https://getfirebug.com/tests/head/_common/testcase.css" type="text/css" rel="stylesheet"/> | |||
</head> | |||
<body> | |||
<header> | |||
<h1><a href="http://code.google.com/p/fbug/issues/detail?id=xxxx">Issue xxxx</a>: Issue summary</h1> | |||
</header> | |||
<div> | |||
<section id="content"> | |||
<!-- | |||
All inspectable elements, form fields etc. needed to execute the test should be placed here. | |||
If you generate output via JavaScript, put it into <section id="output"></section>. | |||
If you don't need any content, you can remove the "content" section. | |||
--> | |||
</section> | |||
<section id="description"> | |||
<!-- | |||
The steps to reproduce the test case should be described here in detail. | |||
--> | |||
<h3>Steps to reproduce</h3> | |||
<ol> | |||
<li>Step 1</li> | |||
<li>Step 2</li> | |||
<li>Step 3</li> | |||
</ol> | |||
<h3>Observed result</h3> | |||
<ul> | |||
<li>Point 1</li> | |||
<li>Point 2</li> | |||
<li>Point 3</li> | |||
</ul> | |||
<h3>Expected result</h3> | |||
<ul> | |||
<li>Point 1</li> | |||
<li>Point 2</li> | |||
<li>Point 3</li> | |||
</ul> | |||
</section> | |||
<footer> | |||
<!-- | |||
Your name and your email address (or other contact information) should be placed here. | |||
This is important in the case we need to contact you for further reference. | |||
--> | |||
<Author name>, <email address> | |||
</footer> | |||
</div> | |||
</body> | |||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -0,0 +1,70 @@ | |||
function runTest() | |||
{ | |||
FBTest.sysout("issue5526.START"); | |||
|
|||
FBTest.openNewTab(basePath + "firebug/5526/issue5526.html", function(win) | |||
{ | |||
detachFirebug(function(win) | |||
{ | |||
FBTest.ok(FBTest.isDetached(), "Firebug must be detached now"); | |||
attachFirebug(function() | |||
{ | |||
FBTest.progress("waiting for detach " + FW.Firebug.chrome.waitingForDetach); | |||
FBTest.ok(FBTest.isMinimized(), "Firebug must be minimized now"); | |||
|
|||
openFirebug(function() | |||
{ | |||
FBTest.ok(FBTest.isDetached(), "Firebug must be detached now"); | |||
FBTest.testDone("issue5526.DONE"); | |||
}); | |||
}) | |||
}); | |||
}); | |||
} | |||
|
|||
// xxxHonza: if this method is generic enough it | |||
// should be moved into FBTest namespace so, other tests | |||
// can reuse it (and it should probably replace the current | |||
// FBTest.detachFirebug API) | |||
function detachFirebug(callback) | |||
{ | |||
var detachedWindow = FBTest.detachFirebug(); | |||
if (FBTest.ok(detachedWindow, "Firebug is detaching...")) | |||
{ | |||
FBTest.OneShotHandler(detachedWindow, "load", function(event) | |||
{ | |||
FBTest.progress("Firebug detached in a new window."); | |||
setTimeout(function() | |||
{ | |||
callback(detachedWindow); | |||
}); | |||
}); | |||
} | |||
} | |||
|
|||
function openFirebug(callback) | |||
{ | |||
FBTest.sendKey("F12"); | |||
|
|||
// This time out is wrong, we need to get detached window, | |||
// register onload event one shot handler and wait till the window | |||
// is loaded. Just like the detachFirebug method does. | |||
setTimeout(function() | |||
{ | |||
callback(); | |||
}, 1000); | |||
} | |||
|
|||
function attachFirebug(callback) | |||
{ | |||
// Attaching Firebug is synchronous? | |||
FBTest.sendKey("F12"); | |||
callback(); | |||
} | |||
|
|||
// xxxHonza: already in FBTest will be part of FBTest 1.10b6 | |||
function isMinimized() | |||
{ | |||
return FW.Firebug.isMinimized(); | |||
} | |||
|