• This project
    • Loading...
  • Sign in

조인천 / Youtube_MPL

%ea%b7%b8%eb%a6%bc1
Go to a project
Toggle navigation Toggle navigation pinning
  • Projects
  • Groups
  • Snippets
  • Help
  • Project
  • Activity
  • Repository
  • Pipelines
  • Graphs
  • Issues 0
  • Merge Requests 0
  • Wiki
  • Snippets
  • Network
  • Create a new issue
  • Builds
  • Commits
  • Issue Boards
  • Files
  • Commits
  • Network
  • Compare
  • Branches
  • Tags
Switch branch/tag
  • Youtube_MPL
  • node_modules
  • formidable
  • node-gently
  • example
  • dog.js
  • 조인천's avatar
    incheon2 · 50c377ec
    50c377ec
    조인천 authored 2019-06-02 19:11:50 +0900
dog.js 411 Bytes
Raw Blame History Permalink
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
require('../test/common');
function Dog() {}

Dog.prototype.seeCat = function() {
  this.bark('whuf, whuf');
  this.run();
}

Dog.prototype.bark = function(bark) {
  require('sys').puts(bark);
}

var gently = new (require('gently'))
  , assert = require('assert')
  , dog = new Dog();

gently.expect(dog, 'bark', function(bark) {
  assert.equal(bark, 'whuf, whuf');
});
gently.expect(dog, 'run');

dog.seeCat();