Skip to content

Commit

Permalink
Copy build to test dir for testing, run directly from test dir.
Browse files Browse the repository at this point in the history
  • Loading branch information
davidkaneda committed Feb 17, 2013
1 parent 48a51cd commit a70a572
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 12 deletions.
11 changes: 8 additions & 3 deletions Gruntfile.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,12 @@ module.exports = (grunt) ->

else
content

test:
expand: yes
cwd: '<%= dirs.build %>'
dest: 'test/build/'
src: '**/*'

zepto:
files: [
expand: yes
Expand Down Expand Up @@ -132,7 +137,7 @@ module.exports = (grunt) ->
cssDir: '<%= dirs.css %>'

qunit:
files: ["<%= dirs.build %>/test/unit/*.html"]
files: ["test/unit/*.html"]

uglify:
options:
Expand Down Expand Up @@ -208,8 +213,8 @@ module.exports = (grunt) ->
grunt.registerTask "jquery-bridge", ["zepto", "copy:jquery-bridge"]

# Tests & checks
grunt.registerTask "test", ["copy:prepare", "qunit"]
grunt.registerTask "cq", ["jshint", "light", "jshint"]
grunt.registerTask "test", ["copy:prepare", "copy:test", "qunit"]

# Full-build tasks
grunt.registerTask "light", ["nuke", "copy:prepare", "compass"]
Expand Down
4 changes: 2 additions & 2 deletions test/unit/jqtouch-with-zepto.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
<title>jQTouch with Zepto</title>
<link rel="stylesheet" href="http://code.jquery.com/qunit/qunit-git.css" type="text/css" media="screen">
<script type="text/javascript" src="http://code.jquery.com/qunit/qunit-git.js"></script>
<script src="../../lib/zepto/zepto.js"></script>
<script src="../../src/jqtouch.js"></script>
<script src="../build/lib/zepto/zepto.js"></script>
<script src="../build/src/jqtouch.js"></script>
</head>
<body>
<h1 id="qunit-header">jQTouch with Zepto</h1>
Expand Down
13 changes: 7 additions & 6 deletions test/unit/jquery-jqtouch.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,13 @@
<!-- adopted from `github.com/madrobby/zepto` and modified -->
<meta charset="utf-8">
<meta name="viewport" content="initial-scale=1.0, maximum-scale=1.0, user-scalable=0">
<title>jQTouch's touch unit tests</title>
<link rel="stylesheet" href="http://code.jquery.com/qunit/qunit-git.css" type="text/css" media="screen">
<script type="text/javascript" src="http://code.jquery.com/qunit/qunit-git.js"></script>
<script src="../../lib/jquery/jquery-1.7.min.js"></script>
<script src="../../src/jqtouch.js"></script>
<script src="../../src/jqtouch-jquery.js"></script>
<title>jQTouch’s touch unit tests</title>
<link rel="stylesheet" href="http://code.jquery.com/qunit/qunit-git.css" type="text/css" media="screen">
<script type="text/javascript" src="http://code.jquery.com/qunit/qunit-git.js"></script>

<script src="../build/lib/jquery/jquery-1.7.js"></script>
<script src="../build/src/jqtouch.js"></script>
<script src="../build/src/jqtouch-jquery.js"></script>
</head>
<body>
<h1 id="qunit-header">jQTouch's touch unit tests</h1>
Expand Down
2 changes: 1 addition & 1 deletion test/unit/touch.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<title>Zepto touch unit tests</title>
<link rel="stylesheet" href="http://code.jquery.com/qunit/qunit-git.css" type="text/css" media="screen">
<script type="text/javascript" src="http://code.jquery.com/qunit/qunit-git.js"></script>
<script src="../../lib/zepto/zepto.js"></script>
<script src="../build/lib/zepto/zepto.js"></script>
</head>
<body>
<h1 id="qunit-header">Touch Test</h1>
Expand Down

0 comments on commit a70a572

Please sign in to comment.