timbles.js icon indicating copy to clipboard operation
timbles.js copied to clipboard

unit tests

Open jennschiffer opened this issue 9 years ago • 3 comments

I just did a big refactor of the very few tests that are on this project, which lead to finding some pretty major bugs. I was able to fix them, so I'm feeling p good about myself lol. Anyway, if anyone can come up with different ways to more strenuously test tables with sorting and pagination, that would be :100:

jennschiffer avatar Nov 01 '15 21:11 jennschiffer

Where we stand now, I think the actual sorting is tested pretty exhaustively. All of the text/value transforms are tested, loading is tested and the behavior of numbers in data-value attributes (natural sort instead of lex.).

What could do with better testing is the behavior of paginated tables. The first page of the paginated table is tested, but that's only a small portion of the things that a paginated table does. Navigation (with buttons or methods) isn't tested, nor are things like the page numbering.

When I find myself with more spare time I might have a look at this and ensure we test pagination more thoroughly. We can probably get away with a simpler test table as well, focusing on just testing the actual paginating (for this new suite).

edelooff avatar Jan 07 '16 16:01 edelooff

i'd be happy to take this on over the next 2 weeks. i'll have some downtime between projects then!

jennschiffer avatar Jan 08 '16 04:01 jennschiffer

I think this is resolved (for now anyway). I can't really think of any parts that seriously lack testing. There are some minor bits like the texts and classes that are set, but I'm not sure they really need the tests.

Mostly a matter of maintaining coverage at this point.

edelooff avatar Feb 17 '16 20:02 edelooff