Sha256: 4e6957ec924fbfdabe220231a5f69add9dc93f3fcd7ce2c690b1c9d69bee0d29

Contents?: true

Size: 804 Bytes

Versions: 17

Compression:

Stored size: 804 Bytes

Contents

require 'hybrid_platforms_conductor/test_only_remote_node'

module HybridPlatformsConductor

  module HpcPlugins

    module Test

      # Test that the hostname is correct
      class Hostname < TestOnlyRemoteNode

        # Check my_test_plugin.rb.sample documentation for signature details.
        def test_on_node
          {
            # TODO: Access the user correctly when the user notion will be moved out of the ssh connector
            "#{@deployer.instance_variable_get(:@actions_executor).connector(:ssh).ssh_user == 'root' ? '' : "#{@nodes_handler.sudo_on(@node)} "}hostname -s" => proc do |stdout|
              assert_equal stdout.first, @node, "Expected hostname to be #{@node}, but got #{stdout.first} instead."
            end
          }
        end

      end

    end

  end

end

Version data entries

17 entries across 17 versions & 1 rubygems

Version Path
hybrid_platforms_conductor-33.5.0 lib/hybrid_platforms_conductor/hpc_plugins/test/hostname.rb
hybrid_platforms_conductor-33.4.0 lib/hybrid_platforms_conductor/hpc_plugins/test/hostname.rb
hybrid_platforms_conductor-33.3.0 lib/hybrid_platforms_conductor/hpc_plugins/test/hostname.rb
hybrid_platforms_conductor-33.2.4 lib/hybrid_platforms_conductor/hpc_plugins/test/hostname.rb
hybrid_platforms_conductor-33.2.3 lib/hybrid_platforms_conductor/hpc_plugins/test/hostname.rb
hybrid_platforms_conductor-33.2.2 lib/hybrid_platforms_conductor/hpc_plugins/test/hostname.rb
hybrid_platforms_conductor-33.2.1 lib/hybrid_platforms_conductor/hpc_plugins/test/hostname.rb
hybrid_platforms_conductor-33.2.0 lib/hybrid_platforms_conductor/hpc_plugins/test/hostname.rb
hybrid_platforms_conductor-33.1.1 lib/hybrid_platforms_conductor/hpc_plugins/test/hostname.rb
hybrid_platforms_conductor-33.1.0 lib/hybrid_platforms_conductor/hpc_plugins/test/hostname.rb
hybrid_platforms_conductor-33.0.4 lib/hybrid_platforms_conductor/hpc_plugins/test/hostname.rb
hybrid_platforms_conductor-33.0.3 lib/hybrid_platforms_conductor/hpc_plugins/test/hostname.rb
hybrid_platforms_conductor-33.0.2 lib/hybrid_platforms_conductor/hpc_plugins/test/hostname.rb
hybrid_platforms_conductor-33.0.1 lib/hybrid_platforms_conductor/hpc_plugins/test/hostname.rb
hybrid_platforms_conductor-33.0.0 lib/hybrid_platforms_conductor/hpc_plugins/test/hostname.rb
hybrid_platforms_conductor-32.18.0 lib/hybrid_platforms_conductor/hpc_plugins/test/hostname.rb
hybrid_platforms_conductor-32.17.1 lib/hybrid_platforms_conductor/hpc_plugins/test/hostname.rb