0

I'm using Eclipse in Windows. I have an application that should be tested on a Linux server. I usually connect to the server via winSCP and putty, but I want to make automated tests.

My questions is: How do I connect to Linux server from Windows to test the application?

Robert Koritnik
  • 103,639
  • 52
  • 277
  • 404
user1464726
  • 21
  • 1
  • 6
  • 2
    You need to search for "java" and "ssh"; you'll find things like http://stackoverflow.com/questions/995944/ssh-library-for-java – vanza Jul 11 '12 at 06:12

3 Answers3

1

In general, the better way is using ci tool like Jenkins. If you want do it by yourself, just act as ci server or plan your test procedure.

Act as ci:

on-development-host:

  1. commit the source code to verion control system

on-linux:

  1. check any changes in the version control system
  2. get latest source code from version control system (git pull or svn update, or any other vcs tool you used)
  3. build app from source code (use build tool: ant or maven)
  4. run test-cases and send test report

Arrange test procedure by yourself:

  1. winscp to linux from your computer
  2. run test-cases and send test report

There is a problem in winscp. It is a gui tool and is difficlut to automate. Ant sshexec and scp task is better for automating test.

qrtt1
  • 7,746
  • 8
  • 42
  • 62
0

You use plink to run commands on the server non-interactively.

Ignacio Vazquez-Abrams
  • 776,304
  • 153
  • 1,341
  • 1,358
0

Go and check for JSCH connction , you can run multiple commands and even scripts(after loading them from your system) using it