2012-05-07 14:27:33 -07:00
|
|
|
/*
|
|
|
|
Licensed to the Apache Software Foundation (ASF) under one
|
|
|
|
or more contributor license agreements. See the NOTICE file
|
|
|
|
distributed with this work for additional information
|
|
|
|
regarding copyright ownership. The ASF licenses this file
|
|
|
|
to you under the Apache License, Version 2.0 (the
|
|
|
|
"License"); you may not use this file except in compliance
|
|
|
|
with the License. You may obtain a copy of the License at
|
|
|
|
|
|
|
|
http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
|
|
|
|
Unless required by applicable law or agreed to in writing,
|
|
|
|
software distributed under the License is distributed on an
|
|
|
|
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
|
|
KIND, either express or implied. See the License for the
|
|
|
|
specific language governing permissions and limitations
|
|
|
|
under the License.
|
|
|
|
*/
|
|
|
|
|
2011-09-01 14:34:11 -07:00
|
|
|
util = require 'util'
|
2011-08-19 20:39:35 -07:00
|
|
|
exec = require('child_process').exec
|
2011-09-01 14:34:11 -07:00
|
|
|
path = require 'path'
|
2011-08-19 20:39:35 -07:00
|
|
|
|
|
|
|
exports['default example project is generated'] = (test) ->
|
|
|
|
test.expect 1
|
|
|
|
exec './bin/create', (error, stdout, stderr) ->
|
2011-08-19 21:50:46 -07:00
|
|
|
test.ok true, "this assertion should pass" unless error?
|
|
|
|
test.done()
|
2011-08-19 20:39:35 -07:00
|
|
|
|
2012-02-01 20:45:49 -05:00
|
|
|
exports['default example project has a ./.cordova folder'] = (test) ->
|
2011-09-01 14:34:11 -07:00
|
|
|
test.expect 1
|
2012-02-01 20:45:49 -05:00
|
|
|
path.exists './example/.cordova', (exists) ->
|
|
|
|
test.ok exists, 'the cordova folder exists'
|
2011-09-01 14:34:11 -07:00
|
|
|
test.done()
|
|
|
|
|
2012-02-01 20:45:49 -05:00
|
|
|
exports['default example project has a /cordova folder'] = (test) ->
|
2011-09-01 14:34:11 -07:00
|
|
|
test.expect 1
|
2012-02-01 20:45:49 -05:00
|
|
|
path.exists './example/cordova', (exists) ->
|
|
|
|
test.ok exists, 'the other cordova folder exists'
|
2011-09-01 14:34:11 -07:00
|
|
|
test.done()
|