File: test_dsl.rb

package info (click to toggle)
ruby-sshkit 1.21.2-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 700 kB
  • sloc: ruby: 3,522; makefile: 2
file content (26 lines) | stat: -rw-r--r-- 455 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
require 'helper'

module SSHKit

  class TestDSL < UnitTest
    include SSHKit::DSL

    def test_dsl_on
      coordinator = mock
      Coordinator.stubs(:new).returns coordinator
      coordinator.expects(:each).at_least_once

      on('1.2.3.4')
    end

    def test_dsl_run_locally
      local_backend = mock
      Backend::Local.stubs(:new).returns local_backend
      local_backend.expects(:run).at_least_once

      run_locally
    end

  end

end