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
using System; | |
using System.Collections.Generic; | |
using System.IO; | |
using System.Linq; | |
using System.Reflection; | |
using NUnit.Framework; | |
namespace MyProject | |
{ | |
[TestFixture] |
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
<CodeSnippet Format="1.1.0" xmlns="http://schemas.microsoft.com/VisualStudio/2005/CodeSnippet"> | |
<Header> | |
<Title>Immediately Invoked Function Expression</Title> | |
<Author>Stephen James (@stephenhjames)</Author> | |
<Shortcut>iife</Shortcut> | |
<Description>Code snippet for an Immediately-Invoked Function Expression</Description> | |
<SnippetTypes> | |
<SnippetType>Expansion</SnippetType> | |
<SnippetType>SurroundsWith</SnippetType> | |
</SnippetTypes> |
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
/*! | |
* RequireJS plugin for async dependency load like JSONP and Google Maps | |
* @author Miller Medeiros | |
* @version 0.0.1 (2011/03/23) | |
* Released under the MIT License <http://www.opensource.org/licenses/mit-license.php> | |
*/ | |
define(function(){ | |
function injectScript(src){ | |
var s, t; |
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
<system.webServer> | |
<httpCompression directory="%SystemDrive%\inetpub\temp\IIS Temporary Compressed Files"> | |
<scheme name="gzip" dll="%Windir%\system32\inetsrv\gzip.dll"/> | |
<dynamicTypes> | |
<add mimeType="text/*" enabled="true"/> | |
<add mimeType="message/*" enabled="true"/> | |
<add mimeType="application/javascript" enabled="true"/> | |
<add mimeType="application/x-javascript" enabled="true"/> | |
<add mimeType="*/*" enabled="false"/> | |
</dynamicTypes> |
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
# npm packages | |
node_modules |
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
{ | |
"name": "lab-karma-require-jasmine", | |
"version": "0.0.0", | |
"description": "A step-by-step lab for setting up a simple JavaScript centric web app using RequireJS, Karma and Jasmine", | |
"main": "index.html", | |
"directories": { | |
"test": "test" | |
}, | |
"dependencies": {}, | |
"devDependencies": {}, |
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
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Lab : Karma, RequireJS, Jasmine</title> | |
</head> | |
<body> | |
<script src="node_modules/requirejs/require.js" data-main="src/main.js"></script> | |
</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
define(["jquery"], function ($) { | |
"use strict"; | |
var App = function (target) { | |
this.target = target || $("body"); | |
}; | |
App.prototype.start = function () { | |
this.target.html("App Started!"); | |
}; |
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
// Karma configuration | |
// Generated on Tue May 27 2014 16:04:16 GMT+0100 (GMT Daylight Time) | |
module.exports = function(config) { | |
config.set({ | |
// base path that will be used to resolve all patterns (eg. files, exclude) | |
basePath: '', | |
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
var allTestFiles = []; | |
var TEST_REGEXP = /(spec|test)\.js$/i; | |
var pathToModule = function(path) { | |
var returnValue = path.replace(/^\/base\//, '').replace(/\.js$/, ''); | |
return returnValue; | |
}; | |
Object.keys(window.__karma__.files).forEach(function(file) { | |
if (TEST_REGEXP.test(file)) { |
OlderNewer