Przeglądaj źródła

[misc] move test scripts into test/ tree

Jakob Ackermann 5 lat temu
rodzic
commit
69df7f5bb3

+ 1 - 1
libraries/redis-wrapper/package.json

@@ -6,7 +6,7 @@
   "author": "ShareLaTeX",
   "author": "ShareLaTeX",
   "license": "ISC",
   "license": "ISC",
   "scripts": {
   "scripts": {
-    "test": "mocha --require coffee-script/register test.coffee"
+    "test": "mocha --require coffee-script/register test/unit/src/*.coffee"
   },
   },
   "dependencies": {
   "dependencies": {
     "coffee-script": "1.8.0",
     "coffee-script": "1.8.0",

+ 1 - 1
libraries/redis-wrapper/health.coffee → libraries/redis-wrapper/test/scripts/standalone.coffee

@@ -1,7 +1,7 @@
 # execute this script with a redis container running to test the health check
 # execute this script with a redis container running to test the health check
 # starting and stopping redis with this script running is a good test
 # starting and stopping redis with this script running is a good test
 
 
-redis = require "./index.coffee"
+redis = require "../../index.coffee"
 
 
 rclient = redis.createClient({host:"localhost",port:"6379"})
 rclient = redis.createClient({host:"localhost",port:"6379"})
 setInterval () ->
 setInterval () ->

+ 1 - 1
libraries/redis-wrapper/test.coffee → libraries/redis-wrapper/test/unit/src/test.coffee

@@ -3,7 +3,7 @@ SandboxedModule = require('sandboxed-module')
 assert = require('assert')
 assert = require('assert')
 path = require('path')
 path = require('path')
 sinon = require('sinon')
 sinon = require('sinon')
-modulePath = path.join __dirname, "./index.coffee"
+modulePath = path.join __dirname, "./../../../index.coffee"
 expect = require("chai").expect
 expect = require("chai").expect
 
 
 describe "index", ->
 describe "index", ->