#!/usr/bin/env smbscript /* test echo pipe calls from ejs */ var options = new Object(); ok = GetOptions(ARGV, options, "POPT_AUTOHELP", "POPT_COMMON_SAMBA", "POPT_COMMON_CREDENTIALS"); if (ok == false) { println("Failed to parse options: " + options.ERROR); return -1; } libinclude("base.js"); /* generate a ramp as an integer array */ function ramp_array(N) { var a = new Array(N); for (i=0;i\n"); exit(0); } if (options.ARGV.length != 1) { println("Usage: samr.js "); return -1; } var binding = options.ARGV[0]; var conn = new Object(); print("Connecting to " + binding + "\n"); status = rpc_connect(conn, binding, "rpcecho"); if (status.is_ok != true) { print("Failed to connect to " + binding + " - " + status.errstr + "\n"); return; } test_AddOne(conn); test_EchoData(conn); test_SinkData(conn); test_SourceData(conn); test_TestCall(conn); test_TestCall2(conn); test_TestSleep(conn); test_TestEnum(conn); test_TestSurrounding(conn); test_TestDoublePointer(conn); print("All OK\n"); return 0;