Welcome to mirror list, hosted at ThFree Co, Russian Federation.

common.js « lib « test « npm-registry-client « node_modules - github.com/npm/cli.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: f9048c0945354a1ae804918e35cf16f63ea15d1b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
var resolve = require("path").resolve
var server = require('./server.js')
var RC = require('../../')

module.exports = {
  freshClient : function freshClient(config) {
    config = config || {}
    config.cache = resolve(__dirname, '../fixtures/cache')
    config.registry = 'http://localhost:' + server.port

    var client = new RC(config)
    server.log = client.log
    client.log.level = 'silent'

    return client
  }
}