diff options
Diffstat (limited to 'js/scripting-lang/analyze_test_differences.sh')
-rwxr-xr-x | js/scripting-lang/analyze_test_differences.sh | 105 |
1 files changed, 0 insertions, 105 deletions
diff --git a/js/scripting-lang/analyze_test_differences.sh b/js/scripting-lang/analyze_test_differences.sh deleted file mode 100755 index 41a2ced..0000000 --- a/js/scripting-lang/analyze_test_differences.sh +++ /dev/null @@ -1,105 +0,0 @@ -#!/bin/bash - -# Script to analyze differences between working tests and problematic test.txt - -echo "=== Test Analysis Tool ===" -echo "" - -echo "1. Checking file sizes:" -echo " Working test files:" -for file in tests/*.txt; do - if [ -f "$file" ]; then - lines=$(wc -l < "$file") - echo " - $(basename "$file"): $lines lines" - fi -done - -echo "" -echo " Original test.txt:" -if [ -f "test.txt" ]; then - lines=$(wc -l < "test.txt") - echo " - test.txt: $lines lines" -else - echo " - test.txt: not found" -fi - -echo "" -echo "2. Testing sections of test.txt:" - -if [ -f "test.txt" ]; then - # Extract first 50 lines and test - echo " Testing first 50 lines..." - head -50 test.txt > temp_section1.txt - if node lang.js temp_section1.txt > /dev/null 2>&1; then - echo " ✅ First 50 lines: PASS" - else - echo " ❌ First 50 lines: FAIL" - fi - rm temp_section1.txt - - # Extract lines 51-100 and test - echo " Testing lines 51-100..." - sed -n '51,100p' test.txt > temp_section2.txt - if [ -s temp_section2.txt ]; then - if node lang.js temp_section2.txt > /dev/null 2>&1; then - echo " ✅ Lines 51-100: PASS" - else - echo " ❌ Lines 51-100: FAIL" - fi - else - echo " ⚠️ Lines 51-100: Empty" - fi - rm temp_section2.txt - - # Extract lines 101-150 and test - echo " Testing lines 101-150..." - sed -n '101,150p' test.txt > temp_section3.txt - if [ -s temp_section3.txt ]; then - if node lang.js temp_section3.txt > /dev/null 2>&1; then - echo " ✅ Lines 101-150: PASS" - else - echo " ❌ Lines 101-150: FAIL" - fi - else - echo " ⚠️ Lines 101-150: Empty" - fi - rm temp_section3.txt - - # Continue with more sections if needed - echo " Testing lines 151-200..." - sed -n '151,200p' test.txt > temp_section4.txt - if [ -s temp_section4.txt ]; then - if node lang.js temp_section4.txt > /dev/null 2>&1; then - echo " ✅ Lines 151-200: PASS" - else - echo " ❌ Lines 151-200: FAIL" - fi - else - echo " ⚠️ Lines 151-200: Empty" - fi - rm temp_section4.txt - -else - echo " test.txt not found" -fi - -echo "" -echo "3. Unique constructs in test.txt:" -if [ -f "test.txt" ]; then - echo " Checking for unique patterns..." - - # Look for unique function call patterns - echo " - Function calls with complex nesting:" - grep -n "add.*add.*add" test.txt | head -3 - - # Look for unique case expression patterns - echo " - Complex case expressions:" - grep -n "case.*case.*case" test.txt | head -3 - - # Look for unique table patterns - echo " - Complex table literals:" - grep -n "\\{.*\\{.*\\}" test.txt | head -3 -fi - -echo "" -echo "Analysis complete." \ No newline at end of file |