csssaz / compilers_project

0 stars 0 forks source link

Add alltest.decaf #3

Closed RdecKa closed 7 years ago

RdecKa commented 7 years ago

I've finished my part. Shall I write the alltest.decaf file (it is a part of submission)?

csssaz commented 7 years ago

I was thinking of testing both lexers with more than one file once I finish :angel: But yes, you can write that one. Would be useful to have (alltest.decaf, expected output) so we can check it actually works? The expected output would be asserted in the automated tests (will commit that later today!), so it's not necessarily a file.

RdecKa commented 7 years ago

Sure, having more tests is a good idea, I'll write some .decaf files (probably tomorrow) and it would be great if you do that as well in case I miss something (but I guess you already plan to do that ;) ). Shall we add those files to new branch? Or directly to master?

But how do you plan to get the expected outputs? Write them by hand? Or can we just compare if outputs of both lexers are the same?

csssaz commented 7 years ago

I will make a subfolder "test" in which we can put all of that (just figuring out how to make the cmakelists and these things for it to work in both of our environments). Should be done by tonight so tomorrow is good!

I think we should have the expected output by hand of at least one short file (not all tokens, just some tricky case we can think of or something like that) so we minimise the chances of both being wrong :v. besides from that, we can compare the output of both :_).