Testing Fundamentals - Non-Functional Testing
What will be the result of this JavaScript code snippet used in security testing?
const input = ""; const safeInput = input.replace(/" as output.
Final Answer:
"alert('XSS')" -> Option AQuick Check:
Replace removes only opening tag, closing remains [OK]Quick Trick: Replace removes only matched text, others stay [OK]
Common Mistakes:
MISTAKES- Expecting both removed
- Confusing replace with replaceAll
- Assuming output is unchanged
