| 1 | // vtest build: !sanitize-address-gcc && !sanitize-address-clang |
| 2 | import encoding.vorbis |
| 3 | import os |
| 4 | |
| 5 | fn test_compilation() { |
| 6 | assert vorbis.wrapper_version() == '1.22' |
| 7 | } |
| 8 | |
| 9 | fn test_decode_file() { |
| 10 | x := vorbis.decode_file(os.join_path(@VEXEROOT, 'examples/sokol/sounds/pickup.ogg'))! |
| 11 | assert x.path.ends_with('pickup.ogg') |
| 12 | assert x.channels == 1 |
| 13 | assert x.sample_rate == 44100 |
| 14 | assert x.sample_len == 5478 |
| 15 | } |
| 16 |