Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

* Removing Tester submodule

  • Loading branch information...
commit 868c4e93f4b48365ce5dfba101d1a600bf0cdb61 1 parent 906ae54
Christoph Pojer cpojer authored
6 .gitmodules
View
@@ -1,9 +1,3 @@
-[submodule "UnitTester"]
- path = UnitTester
- url = git://github.com/anutron/mootools-unittester.git
-[submodule "Tests/UnitTester"]
- path = Tests/UnitTester
- url = git://github.com/anutron/mootools-unittester.git
[submodule "Packager"]
path = Packager
url = git://github.com/kamicane/packager.git
1  Tests/UnitTester
@@ -1 +0,0 @@
-Subproject commit 97696ba5fc2f4b3658f21b956c1eb44bb1682b83
85 Tests/UserTests/Element/Element.Dimensions.offsets.html
View
@@ -1,85 +0,0 @@
-<script>
-window.addEvent('domready', function(){
- var fun = function(pos_style){ $(pos_style).getFirst().set('html', $(pos_style).getOffsets().y); };
- ["fixed", "static", "absolute"].each(function(pos_style){
- fun(pos_style);
- window.addEvent('scroll', function(){
- fun(pos_style);
- });
- });
-});
-</script>
-
-<style>
- #wrapper { width:100%; margin:100px auto; background:#ddd; }
- #fixed { position: fixed; }
- #static { position: static; }
- #absolute { position: absolute; }
- .position-type { background:gray; color:black; padding:10px; width:30%; }
-</style>
-
-<div id="wrapper">
- <div class="position-type" id="fixed">FIXED <span class="val"></span></div>
- <div class="position-type" id="static">STATIC <span class="val"></span></div>
- <div class="position-type" id="absolute">ABSOLUTE <span class="val"></span></div>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
-</div>
10 Tests/UserTests/Element/Element.Dimensions.offsets.js
View
@@ -1,10 +0,0 @@
-{
- tests: [
- {
- title: "Element.offsets",
- description: "Tests the offset logic for elements.",
- verify: "When you scroll does offset value remain fixed in place?"
- }
- ],
- otherScripts: ['DomReady']
-}
63 Tests/UserTests/Element/Element.Dimensions.scrollSize.html
View
@@ -1,63 +0,0 @@
-<div id="value"></div>
-<div id="wrapper">
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
- SCROLL<br/>
-</div>
15 Tests/UserTests/Element/Element.Dimensions.scrollSize.js
View
@@ -1,15 +0,0 @@
-{
- tests: [
- {
- title: "Element.scrollSize",
- description: "Checks the scrollsize of the document.",
- verify: "Do the sizes injected into the document content seem correct (the scrollsize should be larger than the frame size)?",
- before: function(){
- $('value').set('html', 'frame size: {frame}, scroll size: {scroll}'.substitute({
- frame: document.body.getSize().y,
- scroll: document.body.getScrollSize().y
- }));
- }
- }
- ]
-}
12 Tests/UserTests/Element/Element.iframe.html
View
@@ -1,12 +0,0 @@
-<style>
- #frames iframe { width:1px; height: 1px; background: #fff; border: 0; }
- #result { width:100%; background:#ddd; }
-</style>
-
-<div id="frames">
-<iframe id="existingFrame" src="test_frame.html" frameborder="0"></iframe>
-</div>
-
-<div id="result">
-Not loaded.
-</div>
16 Tests/UserTests/Element/Element.iframe.js
View
@@ -1,16 +0,0 @@
-{
- tests: [{
- title: "Element.iframe",
- description: "Tests the loading of IFrames.",
- verify: "Did the text \"Loaded!\" show up?",
- before: function(){
- var result = $('result');
- new IFrame('existingFrame', { onload: function(){
- result.set('text', 'First frame loaded.');
- (new IFrame({ src: 'test_frame.html?' + $time, onload: function(){
- result.set('text', 'Loaded!');
- }})).inject('frames');
- }});
- }
- }]
-}
1  Tests/UserTests/Request/Request.all.html
View
@@ -1 +0,0 @@
-<div id="log" style="margin: 8px"></div>
47 Tests/UserTests/Request/Request.all.js
View
@@ -1,47 +0,0 @@
-{
- tests: [
- {
- title: "Request",
- description: "Sends an AJAX request to the server.",
- verify: "Did the ajax log to the screen a success?",
- before: function(){
- new Request({
- url: 'UserTests/Request/simple.php',
- method: 'get',
- onRequest: function(){
- $('log').adopt(new Element('li', {
- html: 'attempting request...'
- }))
- },
- onSuccess: function(r){
- $('log').adopt(new Element('li', {
- html: 'success: ' + r
- }))
- }
- }).send();
- }
- },
- {
- title: "Request + Hash",
- description: "Sends an AJAX request to the server with a fragment at the end of the URL.",
- verify: "Did the ajax log to the screen a success?",
- before: function(){
- new Request({
- url: 'UserTests/Request/simple.php#test',
- method: 'get',
- onRequest: function(){
- $('log').adopt(new Element('li', {
- html: 'attempting request...'
- }))
- },
- onSuccess: function(r){
- $('log').adopt(new Element('li', {
- html: 'success: ' + r
- }))
- }
- }).send();
- }
- }
- ],
- otherScripts: ['Element']
-}
7 Tests/UserTests/Request/simple.php
View
@@ -1,7 +0,0 @@
-<?php
-if (isset($_GET['sleep'])) sleep($_GET['sleep']);
-if (isset($_GET['num'])){
- echo 'requested: '.$_GET['num'];
-} else {
- echo 'ajax request successful';
-} ?>
9 Tests/UserTests/tests.json
View
@@ -1,9 +0,0 @@
-{
- "Element": {
- "Element":["iframe"],
- "Element.Dimensions":["offsets", "scrollSize"]
- },
- "Request": {
- "Request":["all"]
- }
-}
15 Tests/config.js
View
@@ -1,15 +0,0 @@
-var UnitTester = {
- site: 'MooTools Core',
- title: 'Unit Tests',
- path: 'UnitTester/',
- ready: function(){
- var sources = {
- mootoolsCore: '..'
- };
- new UnitTester(sources, {
- 'mootools-core': 'UserTests'
- }, {
- autoplay: true
- });
- }
-};
76 Tests/index.html
View
@@ -1,76 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
-<head>
- <title>Unit Tester</title>
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
-</head>
-<body>
- <script src="config.js" type="text/javascript" charset="utf-8"></script>
- <script>
- function scripter(scr) {
- document.write("<scri"+"pt src='"+scr+"'> </scr"+"ipt>");
- };
- scripter(UnitTester.path+'assets/mootools-1.2.js');
- scripter(UnitTester.path+'assets/mootools-more-1.2.js');
- scripter(UnitTester.path+'assets/clientside.js');
- scripter(UnitTester.path+'assets/UnitTester.js');
- scripter(UnitTester.path+'assets/posteditor.js');
- scripter(UnitTester.path+'assets/Debugger.cnet.js');
-
- document.write('<link rel="STYLESHEET" type="text/css" href="'+UnitTester.path+'assets/tests.css"/>');
- </script>
- <script>
- window.addEvent('domready', function(){
- $('script').set('value', '');
- new PostEditor('script');
- });
- </script>
-
- <div id="title">
- <h1>
- <div style="float:right; margin-right: 20px">
- <a href="readme.html">readme &raquo;</a>
- </div>
- <script>document.write(UnitTester.site);</script> <span><script>document.write(UnitTester.title);</script></span>
- </h1>
- </div>
- <center class="clearfix">
- <div id="testBox">
- <div id="testLoader">
- <h2>Load tests:</h2>
- <dl id="testLoaderSel">
- </dl>
- </div>
- <div id="testFrameContainer">
- <iframe src="test_frame.html" id="testFrame"></iframe>
- <div>
- <b>manual code entry:</b>
- <center>
- <textarea></textarea>
- <div class="handle"></div>
- </center>
- <button>execute code</button>
- </div>
- </div>
- <div id="script">
- <dl id="tests"></dl>
- </div>
- </div>
- </center>
- <code id="testTemplate">
- <dt><b>{title}</b> <button>run test</button></dt>
- <dd>
- <p>{description}</p>
- <textarea>{body}</textarea>
- <div class="handle"></div>
- <div class="verify">
- <p>{verify}</p>
- <div class="actions">
- <a class="pass">yes</a>
- <a class="fail">no</a>
- </div>
- </div>
- </dd>
- </code>
-</body>
-</html>
44 Tests/test_frame.html
View
@@ -1,44 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
-<head>
- <title>Unit Test Runner</title>
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
- <script>
- //map dbug in this frame to the parent logger
- var dbug = window.parent.dbug;
- if (!window.console) window.console = dbug;
- document.write('<link rel="stylesheet" type="text/css" media="screen" href="'+window.parent.UnitTester.path+'assets/tests.css" />');
- //these two methods are referenced in UnitTester.js via the parent window
- //define $exec, which needs to work w/o any dependencies for the test framework
- function $exec(text){
- if (!text) return text;
- if (window.execScript){
- window.execScript(text);
- } else {
- var script = document.createElement('script');
- script.setAttribute('type', 'text/javascript');
- script.text = text;
- document.getElementsByTagName('head')[0].appendChild(script);
- document.getElementsByTagName('head')[0].removeChild(script);
- }
- return text;
- };
- //loads a script into the document; no dependencies
- var $LoadScript = function(scr, onload){
- var script = document.createElement('script');
- script.onload = onload || function(){};
- script.src = scr;
- var head = document.getElementsByTagName('head')[0];
- head.appendChild(script);
- };
- </script>
- <style>
- body {
- margin: 0px;
- padding: 15px;
- }
- </style>
-</head>
-<body class="test_iframe">
-</body>
-</html>
Please sign in to comment.
Something went wrong with that request. Please try again.