npm or yarn command error – cli.js not found

While working on a project, I needed to use npm packages and I received a strange error while trying to use them. I ended up with the same error for yarn commands. Now, I had used npm some time back and did not have any issues.

Below is the error I ended up with each time I tried a npm or a yarn command.

internal/modules/cjs/loader.js:883  

throw err;

Error: Cannot find module ‘C:\Program Files\nodejs\node_modules\npm\bin\node_modules\npm\bin\npm-cli.js’

Solutions I tried and did not work for me:

  1. Reinstall npm.
  2. Repair npm
  3. Update my .npmrc file
  4. Restart the system! – that’s what the IT service center asks you to do first thing when you contact them….

What solved the problem?

So, obviously I tried and find the file mentioned in the error in my node.js folder. I obviously found it and banged my head on the wall!

Finally, I tried to trace the file by exact path when I noticed that the following part was extra in there –

node_modules\npm\bin

The correct path should have been “C:\Program Files\nodejs\node_modules\npm\bin\ npm-cli.js”

And that’s wen I went back and looked at my environment variables and found following culprit!!

npm path environment entry

All I had to do was delete this entry, restart my command line and BINGO!

Finally, the moral of the story is – the system variable for npm should be as below:

npm path environment entry

Now, The question is how did that erroneous entry landed in my system variables? There could be multiple reasons for it like:

  1. I manually added it and obviously do not remember!
  2. At some point of time, my system some how had multiple versions of node.js
  3. It got corrupted while updating the node.js versions.

Hope this helps someone in need. Till then,

Happy Coding 😊

SoapUI GUI freeze in Windows

I Installed SoapUI and it kept on freezing for all requests. Obviously I googled it and found a lot of possible solutions. Here is the solution that worked for me and helped me resolve the SoapUI GUI freeze
1.    Navigate to the installation directory. It must be something similar to:
C:Program Files (x86)SmartBearSoapUI-5.5.0bin
2.    Open the .vmoptions file in notepad and add below line:
-Dsoapui.jxbrowser.disable=true
3.    Save the file and restart SOAPUI.
This solution might or might not work for all.
Do let me know if it worked or not for you. And also share what worked for you, i would be happy to update the post with other solutions that worked!
Happy API Testing!

Software Testing Abbreviations and Acronyms

Below is a list of Acronyms or Abbreviations I could collect from various sources on Google related to Software Testing

ABI
Application Binary Interface
ACC
Attribute Component Capability
AIAT
Artificial Intelligence Applications Testing
ALM
Application Lifecycle Management
AMC
Average Method Complexity
AMDD
agile model-driven development
ANSI
American National Standards Institute
API
Application Programming Interface
ASCII
American Standard Code for Information Interchange
ASTF
Automated Software Test Framework
ATP
Acceptance Test Procedure
ATLM
Automated testing lifecycle methodology
AUT
Application Under Test
BDD
Business Driven Development
BERT
Bit Error Test (Diagnostic Tests)
BIST
Built-in self-test (Diagnostic Tests)
BITE
Browser Integrated Test Environment
BFV
Bug fix verification
BR
Business Requirement
BRD
Business Requirement Document
BRS
Business Requirement Specification
BVA
Boundary Value Analysis
CASE
Computer-Aided Software Engineering
CAST
Computer Aided Software Testing
CCB
configuration control board
CDR
Critical Design Review
CE
Critical Error
CHAP
Challenge Handshake Authentication Protocol
CID
Configuration identification
CM
Configuration management
CMM
Capability Maturity Model
CMMI
Capability Maturity Model Integrated
CMP
Configuration Management Plan
CMT
Configuration Management Tool
COF
Cost of Failure
COQ
Cost of Quality
COTS
Commercial Off-The-Shelf Software
CR
Change Request
CRUD
Create, Read, Update, Delete
CTP
Critical Testing Processes
DDP
Defect Detection Percentage
DFD
Data Flow Diagram
DOM
Document Object Model
DSDM
Dynamic Software Development Method
DRE
Defect Removal Efficiency
EP
Equivalence Partitioning
ERD
Entity Relationship Diagram
ETA
Estimated Time of Arrival
ETL
Extract Transformation Load
FAQ
Frequently Asked Questions
FDD
Functional Design Document
FDD
Feature Driven Development
FMEA
Failure Mode and Effect Analysis 
FPA
Function Point Analysis
FTP
File Transfer Protocol
FVT
Function verification test
GUI
Graphical User Interface
GTA
Google Test Analytics
HIPO
Hierarchy, Input, Processing, Output
HLD
High Level Design
HP QC
Hewlett Packard Quality Center
IDD
Interface design document
IDE
Integrated Development Environment
IDEAL
Initiating, Diagnosing, Establishing, Acting & Learning
IDL
Interface design language
IEEE
Institute of Electrical and Electronics Engineers
ISO
International Organization for Standards
ISAKMP
Internet Security Association and Key Management Protocol
ISDN
Integrated Services Digital Network
lSLE
Integrated Software Lifecycle Environment
ISTQB
International Standard Testing Quality Board (Certification)
JAD
Joint Application Development
JDBC
Java Database Connectivity
JTC1
Joint Technical Committee 1
KBSA
Knowledge-Based Software Assistant
KLOC
Thousands of lines of code
KM
Knowledge Management
LCL
lower control limit
LCSAJ
Linear Code Sequence And Jump (a software analysis method)
LOC
lines of code
LSRT
Long-Sequence Regression Testing
MDD
model-driven development
MTBF
Mean Time Between Failure
MTTF
Mean Time To Fail
MTTR
Mean Time To Repair
MTTCF
Mean time to critical failure
MVP
Minimum Viable Product
NCSA
National Cyber Security Alliance
NDA
Non-Disclosure Agreement
NFR
Nonfunctional requirements
NIST
National Institute of Standards and Technology
NBS
National British standard
OCM
Operational configuration management
ODBC
Open Database Connectivity
OKRs
Objectives and key results
OLAP
On Line Analytical Processing
OLTP
On Line Transactional Processing
ORD
Object Relationship Diagram
OS
Operating System
OSI
Open Systems Interconnection
PA
Physical Audit
PCA
Performance and Coverage Analysis
PDR
Preliminary design review
PERT
Program Evaluation and Review technique Diagram
PIR
Post Implementation Review
PCRTS
Problem and Change Request Tracking System
PIM
Platform-Independent Model
PIM
Platform-independent model
POC
Proof of Concept
POF
Probability of Failure
POI
Poor Obfuscation Implementation
POST
Power- On Self – Test (Diagnostic Tests)
PSI
Platform-Specific Implementation
PTR
Problem trouble report
QA
Quality Assurance
QC
Quality Control
QMS
Quality Management System
QoS
Quality of Service
QUES
Quality Evaluation System
RAD
Rapid Application Development
RAT
Real Application Testing
RCA
Root Cause Analysis
RFC
Request For Change/Comments
ROI
Return on Investment
RIB
Reflexive User Interface Builder
RFP
Request for Proposal
RMI
Remote Method Invocation
RPF
Record and Playback framework
RST
Reverse Semantic Traceability
RTM
Requirements traceability matrix

SA
Structured Analysis
SADT
Systems Analysis and Design Technique
SCA
Static Code Analysis
SC
Security Checklist
SCA
Source Code Analyzer
SC
Standards committee
SCR
Software Change Request
SDD
System and software Design Document
SDK
Software Development Kit
SDLC
Software Development Life Cycle
SDP
Software development plan
SEI
Software Engineering Institute
SEO
Search Engine Optimization
SIR
System Investigation Report
SIT
System Integration Testing
SLA
Service Level Agreement
SLC
Software life cycle
SOA
Service Oriented Architecture
SQL
Structural Query Language
SQS
Software quality system
SQSP
Software quality system plan
SRD
Specification Requirement Document
SRR
Software requirements review
SRS
Software Requirement Specification
SMARTS
Software Maintenance and Regression Test System
SSH
Secure Shell
STAF
Software testing automation framework
STEP
Systematic Test and Evaluation Process
START
Structured Testing and Requirements Tool
STR
Software trouble report
STR
System trouble report
SIM
Subscriber Identity Module
ST
State Table
Sc
Security
ST
System Testing
STLC
Software Testing Life Cycle
SUT
System Under test
SUMI
Software Usability Measurement Inventory
TCAT
Test Coverage Analysis Tool
TCB
Trusted Computing Base
TDD
Test Driven Development
TDGEN
Test filelData Generator
TLS
The Transport Layer Security
TMM
Test Maturity Model
TOE
Target of Evaluation
TPA
test point analysis
TPI
Test Process Improvement
TPT
Time Partition Testing
TQC
Total quality control
TTCN
Testing and Test Control Notation
TTM
Test Traceability Matrix
TRR
test readiness review
TSR
Test Summary Report
UAT
User Acceptance Testing
UCL
upper control limit
UDF
unit development folder
UDDI
Universal Description, Discovery and Integration
UML TP
UML Testing Profile
USM
User-based Security Model
UTC
Usability-Test Candidate
UI
User Interface
UML
Unified Modelling Language
URI
Uniform Resource Identifier
URL
Uniform Resource Locator
V & V
Verification and Validation
VE
Virtual Environment
VM
Virtual machine
VU
Virtual Users
WIP
Work In Progress
WSJF
Weighted Shortest Job First
XML
Extensible Markup Language
XP
eXtreme Programming
XSS
Cross Site Scripting

Excel Error – Unable to read file followed by file format or extension is not valid

Sometime, the users suddenly start getting the error- “Unable to read file.”, every time a new excel sheet is opened.
In such situation, generally, the error appears every time the user opens an existing or even new excel file.

On clicking OK, another error is displayed as below.

When clicked Ok, the file opens fine.
Following is the solution which worked for me:
  1. Search for the “XLStart” folder in machine. It can also be at multiple locations.
  2. C:UsersAppDataRoamingMicrosoftExcelXLStart

  3. Delete the file – “~$Book.xltx”. or other corrupted file as displayed in the message.
  4. Open excel again to verify that the error message is not displayed now.

SAP Warning Message – “A script is attempting to access/attach SAP GUI” Upon Running Automated Script

While running an automated script on SAP GUI, a warning message – “A script is attempting to access SAP GUI” is displayed.

In some cases, the message can also be – “A script is trying to attach to GUI“. The solution to both is same.
This warning can be disabled with following steps:
  1. Launch to your SAP GUI application manually.
  2. Navigate to ‘Options’ as below or press “Alt F12” and click ‘Options.
    1. Select “Accessibility & Scripting”.

        1. Expand ‘Accessibility & Scripting’ and select “Scripting”.
        2. If the warning message is being thrown, the option “Notify when a script attaches to SAP GUI” would be checked. Un-check following options:
          1. Notify when a script attaches to SAP GUI
          2. Notify when a script opens a connection. Click “Apply” followed by “OK”.

        3. Please note that since the notification is now disabled, care must be taken to prevent the system from plausible threats and unwanted applications.

        How To Find If The MS Office Version is 32 or 64 Bit?

        Whenever we need to install a new software or tool, the most basic question one need to answer is to find the version of MS Office. So, want to find if you’re running the 32 bit or the 64 bit version of Office 2010? 
        Following are the steps to  find out:
        1. Open any MS Office application – Word/Excel/Power point or any other.
        2. Click ‘File’ Menu.
        3. Click at ‘Help’.
        4. The Office version is displayed on right hand side as highlighted in red box.

        ms office version

        MS-Excel 32 Bit
        And it’s done! Quite easy right?
        The steps to find the version would be almost similar for all office applications and any windows version. 
         
        Hope it helped.
         
        Also check the below link for more posts related to MS Office:

        Removing Port Number from QC/ALM URL

        We had been struggling to get rid of the port number in qc URL. Finally, we got it done with the help of HP Support.
        Below is the solution we have found to remove the port number 8080 from QC URL:

        1. Update the port number to 80 in configuration files of the application. In this case, they were ‘qcconfigfile.properties’ and ‘jetty.xml’.
        2. The ALM service would not start now as port 80 is likely to be used by other processes.
        3. Release port number 80 from all processes.
          • The command “netstat -o -n -a | findstr 0.0:80” help us find out if the port is being used or not.
          • If any website in IIS points to port 80, update the same.
        4. Start the ALM service
        5. Re-Start any other services stopped.

        In this case, we stopped 3 services – World Wide Web Publishing Service, Windows Remote Management (WS-Management) Service and IIS Admin Service

        Mobile Application Types – Native, Web and Hybrid

        The mobile apps are broadly classified under three categories:
        • NATIVE APPLICATION – A native application (native app) is an application program that is developed for use on a particular platform or device iPhone or iPad apps built using Objective-C, and Android application built with Java. Native apps are installed through an application store (such as Google Play or Apple’s App Store). For example, Camera+ app for Apple’s iOS devices.
          • Advantages:
            • Native apps perform faster
            • Native apps provide easy access to all native features of the device
            • Native apps generally operate in offline mode
            • Native apps are fully supported from concerned app stores
            • Because of their support, Native apps provide better security
          • Disadvantages:
            • Native apps are expensive to develop because of their platform dependency
            • Maintenance is also expensive for Native apps.
            • Different teams need to me maintained and tracked for different platforms
            • Multiple versions are often required to be maintained
            • Native apps need approval from app stores to be published and this may prove tedious and time consuming in case the app is not developed with high standards.
        • WEB APPLICATION – Web applications are webpages that look like an app. They are basically Internet-enabled apps that are accessible via the mobile device’s Web browser. Web apps are accesses via browsers are not required to be downloaded on to the device. Web apps are built using HTML5, CSS3 etc. 
          • Advantages:
            • Web apps are platform independent and can be used on all devices irrespective of operating systems.
            • Since Web apps are platform independent, deployment is easier for them
            • As web apps are not downloaded on devices, users need not worry about versions and updates released.
          • Disadvantages
            • The native API’s and device specific features are not accessible to Web apps which limit their scope of usage.
            • Since Web apps are not listed in app stores, users may find it difficult to find them
            • Security is also a concern with Web apps as it’s all internet based and come with it’s own set of vulnerabilities
            • All Web apps may not always work with multiple browsers. Thus is also adds to the cost of developing and maintenance.
            • Web apps need internet connection to operate and do not work offline
        • HYBRID APPLICATION– Native apps are part native apps, part web apps. They are installed in the same way as native apps and use the web apps technologies to perform certain functions. Actually, it’s very hard for the users to differentiate between native and hybrid apps. Hybrid app may look an easy option for websites which want to be listed in app stores without spending much and required effort to develop a native version of themselves.
          • Advantages:
            • Because most of the development is done using web technologies, hybrid apps are faster and easier to develop as compared to Native apps.
            • Hybrid app come with best of both Web and Native apps
          • Disadvantages:
            • Along with best, worst of both Native and web apps is also packaged in Hybrid apps
            • The use of native features of device is limited
            • Performance is not up to the mark when compared with Native apps
            • While most of the code is written in web technologies and is platform independent, there is some part of code which need to be designed as per the platforms of devices.

        What is Mobile Application or Mobile App

        With the advancement of technology, the mobile phone has advanced at rapid fast speed. There was a time when we were surprised that we could take pictures and videos from mobile phone. Before people could digest it properly, came a device that makes calls, plays videos, takes pictures, and receive/send email, more. All this with a regular phone! They are definitely smart – Smartphone. Carrying a small phone is almost equivalent to carrying a pocket-sized personal computer. They have an operating system of their own such as Google’s Android or Microsoft’s Windows Mobile.

        Mobile Application or Mobile App
        As per Wikipedia, A mobile app is a computer program designed to run on smartphonestablet computers and other mobile devices.
        Anyone who uses a smartphone/tablet most probably uses apps. There is hardly any task which cannot be done on a smartphone/tablet as compared to traditional desktops/laptops. There are thousands of apps available for all operating systems. Name a thing or game, and we have a mobile app for it – News, Weather, chatting, Facebook, email, moves, trains, flights, everything.
        While most applications function independently, but some of them integrate with tools in other media. For example, some websites have a different user interface for mobile and desktop version, while others have a separate app for the same – like Facebook. There are some apps which use location-based features  – like maps, weather etc.
        How to download and use an app
        Straight answer would be – A mobile app is used on a smartphone like iphone, Samsung S2/3/4 etx series, HTC mobiles etc or a tablet like – iPad, tab etc. It is to be noted that all apps do not work on all devices. It depends on the operating systems – ios, Android etc. For example, there is an app called iTunes – which works only on ios devices – iPhone/iPad.
        The app needs to be downloaded on the device to use. All operating systems have their online app-stores from where, the users can search and download and install the apps. Some of the apps are free for use while some of them may charge the users. For example, the Facebook app is free for use on all devices and operating systems while the ‘what’s app’ charges ios users a one-time fees and is free for other operating systems (not sure if that’s updated now).

        Types of Mobile Applications:
        1. Native App
        2. Web App
        3. Hybrid App

        Save a powerpoint presentation as a template

        Many times, we choose a presentation template and apply some changes to suit our need. In fact, most of the companies have a predefined template for presentations to be used. This is achieved by creating customized templates and saving them as template files. A template file (.potx/.pot) saves all the customizations made to slide masters, slide layouts, and themes to reuse in other presentations.

        When we create a presentation, and then save it as a Power Point Template (.pot) file, can be reused more than once. Thus saving the presentation as a template offers the following advantages:
        • The exact slide layout can be used in other presentations
        • The template can also be to existing presentations to quickly update the way they look.
        • The template can be used to quickly create a new presentation.
        • The template file can be shared with friends and colleagues.


        To save the presentation as a template:
        1. On the File menu, click Save As.
        2. In the File name box, type a name for the template.
        3. In the Save as type list, click PowerPoint Template (.potx/.pot). As soon as the type is changed to power point template, the default location(might be different for different windows and office versions) “C:UsersName>AppDataRoamingMicrosoftTemplates”. Copy and save the path somewhere for future, in case the template does not appear by default in the list while creating new templates.
        4. Click Save.