I am learning some programming interview questions so I've coded FizzBuzz. I'm trying to comprare the output of my program to a known good output that's in a .txt file.
How do I check that
node fizzbuzz.js output is line by line equal to a
expected-output.txt file, or even
I've tried this as suggested in the duplicate question:
diff -u expected-output.txt <(node fizzbuzz.js)
diff outputs nothing and never seems to quit until I
^C. The program by itself runs fine, and so does
diff -u expected-output.txt <(cat test.txt), it just doesn't seem to play well with
node for some reason.