5 April 2024 Leave a comment Tech-Help
If you’re delving into the world of automation testing with Appium on an Ubuntu system, setting it up correctly is essential. This guide will walk you through the process of installing Appium without requiring sudo rights, which is crucial for its proper functioning.
Prerequisites
Before you begin, ensure that you have not installed Node.js using apt-get. If you have, you’ll need to remove it to prevent permissions issues.
sudo apt-get remove nodejs
sudo apt-get remove npm
Installation Steps
Download Node.js: Grab the latest Node.js Linux binaries from the official Node.js website.
Extract Node.js: Place the downloaded file in a directory where you have regular user permissions, such as your home directory, and extract it.
tar -xvf <downloaded_binary_tar.gz>
Update PATH Variable: Add the Node.js binaries to your PATH by editing your
~/.bashrc
file.export PATH=$PATH:<full_path_of_the_extracted_node_folder>/bin
Install Appium: Open a new terminal window and install Appium globally using npm (Node Package Manager).
npm install -g appium appium
Verification
Once you’ve installed Appium, you can verify the installation by running the appium
command in your terminal. You should see a message indicating that Appium has started successfully.
Additional Notes
Remember, it’s important not to use sudo when installing Node.js and Appium, as this can lead to permission issues that will prevent Appium from working correctly. Following the steps above should provide you with a smooth installation experience.
Conclusion
With Appium set up on your Ubuntu machine, you’re now ready to start automating your Android testing processes. If you encounter any issues, ensure that you followed the steps without using sudo and that the PATH variable is correctly set up.