Closed desyncr closed 7 years ago
Well, not specifically for travis, but this could make us able to check memory defaults in a breeze.
Is it ok to make zpm_memory.sh
executable?
and to have something like
export PATH=$PWD/util:$PATH
in tests/setup.sh
or Makefile
's test target?
I'd put it on a make target:
make valgrind
I guess we can set up a 'zpm' function/alias rather than using sed.
it looks like alias will work 🍾 should we add a header in every test file?
[ -z "$ZPM_MEMORY" ] && alias zpm="$ZPM_MEMORY"
then
valgrind:
export ZPM_MEMORY="$PWD/tests/zpm_memory.sh
make test
unset ZPM_MEMORY
changing test files would be easy:
for test_file in *.t :(
do echo -e "[ -z \"\$ZPM_MEMORY\" ] && alias zpm=\"\$ZPM_MEMORY\"\n$(cat $test_file)" > "$test_file"
done
what do you think?
I was thinking on adding it to the tests/setup.sh
. I'd also use Travis CI's build matrix feature.
Here's an (untested) patch. Let me know what you think!
Here's an (untested) patch. Let me know what you think! Nifty!
Want to take over this task? I have done the Travis CI part and you seem more competent with valgrind
and c
in general.
That fine 😺 I'll work on a PR as soon as I finish the huge Gwion refactor task I'm in right now.
I've got something. see #27.
Gonna take a look at it tonight! Thanks!
Can be closed as #27 has been merged. :smile:
Closing this!
http://valgrind.org/docs/manual/quick-start.html