Anonymous Maarten
f45761908a
Move check for SDL_Delay upper bounds to testtimer
2023-09-25 18:02:40 +02:00
Anonymous Maarten
0e955a9127
cmake: run testautomation with CTest
2023-09-25 18:02:40 +02:00
Anonymous Maarten
4c3e84897f
testspriteminimal: make standalone by embedding icon.bmp
2023-09-19 17:58:25 +02:00
Anonymous Maarten
a2e17852d9
cmake: make sure SDL_GetPrefPath is run before testfilesystem
...
60 seconds timeout ought to be sufficient.
2023-09-08 09:05:58 -04:00
Anonymous Maarten
a5d9db0cd0
cmake: build tests for UWP
2023-08-12 17:37:52 +02:00
Anonymous Maarten
1a7a74fb2e
cmake: build emscripten tests as html page
2023-08-12 17:37:20 +02:00
Anonymous Maarten
64d570f027
Add minimal http server for emscripten test apps
2023-08-12 17:37:20 +02:00
Simon McVittie
55cf1abaa6
test: Don't flag testsurround as suitable for non-interactive use
...
According to #8088 it has no value as an automated test, and by
default it takes long enough to hit the default test timeout.
Resolves : #8088
Signed-off-by: Simon McVittie <smcv@collabora.com>
2023-08-08 08:45:57 -07:00
Ryan C. Gordon
2de9253b6c
test: Added testaudio
2023-08-02 15:02:32 -04:00
Ryan C. Gordon
0eda582160
testaudiostreamdynamicresample: Load sample.wav correctly.
2023-07-30 23:00:52 -04:00
Ryan C. Gordon
47b0321ebf
test: Removed loopwavequeue.c; obsolete in SDL3.
2023-07-30 11:55:57 -04:00
Anonymous Maarten
3ab4665956
cmake: bump minimum required CMake version to 3.16
...
main features:
- No more sdl-build-options/sdl-shared-build-options/sdl-global-options
- Dependency information is stored on SDL3-collector for sdl3.pc
- Use helper functions to modify the SDL targets;
- sdl_sources to add sources
- sdl_glob_sources to add glob soruces
- sdl_link_dependency to add a link dependency that might also
appear in sdl3.pc/SDL3Config.cmake
- sdl_compile_definitions to add macro's
- sdl_compile_options for compile options
- sdl_include_directories for include directories
They avoid repeated checks for existence of the SDL targets
- A nice feature of the previous is the ability to generate
a sdl3.pc or SDL3Config.cmake that describes its dependencies
accurately.
various:
- remove duplicate libc symbol list
- add CheckVulkan
- remove unused HAVE_MPROTECT
- add checks for getpagesize
2023-07-20 17:58:06 +02:00
Anonymous Maarten
a4bb4eef73
cmake: create Android jars + apks for tests
2023-07-20 16:54:29 +02:00
Anonymous Maarten
87ccb886fe
cmake: remove ability to build tests as a standalone project
2023-07-16 20:22:41 +02:00
Anonymous Maarten
80da0cf06d
cmake: convert bmp images to c headers using python script
...
A pure CMake script was too slow
2023-07-16 16:31:06 +02:00
Sam Lantinga
505a8dfb15
testcontroller replaces gamepadmap
2023-07-16 04:32:12 -07:00
Sam Lantinga
ca492dff18
Renamed testgamepad to testcontroller
...
The program does more than just test gamepads, and will eventually map them as well.
2023-07-16 04:32:12 -07:00
Sam Lantinga
d2d26c7b1e
testgamepad replaces testjoystick
2023-07-16 04:32:12 -07:00
Sam Lantinga
8f5ec2f596
Added shared code between testgamepad and gamepadmap
...
The goal is to eventually create a single program that can do mapping and testing of game controllers.
2023-07-09 19:24:36 -07:00
Anonymous Maarten
b4291412a4
tests: build tests with C90 standard
...
C90 mode is disabled for:
- testautomation: use of isnan/isfinite
- testlock: use of kill
- testvulkan: use of c++ style strings in vulkan.h
2023-05-27 01:49:07 +02:00
Ryan C. Gordon
e474047ff8
rwlock: Added SDL_rwlock API for shared locks.
2023-04-27 21:54:02 -04:00
Ryan C. Gordon
e5a6c24c82
audio: Redesigned audio conversion code for SDL3.
...
- SDL_AudioCVT is gone, even internally.
- libsamplerate is gone (I suspect our resampler is finally Good Enough).
- Cleanups and improvements to audio conversion interfaces.
- SDL_AudioStream can change its input/output format/rate/channels on the fly!
2023-04-27 18:35:15 -04:00
Anonymous Maarten
cb076b83ff
cmake: fix testnative for Macos
2023-03-28 04:01:50 +02:00
Anonymous Maarten
1259a60731
cmake: build tests as library on Android
2023-03-28 01:30:55 +02:00
Anonymous Maarten
b8b852a55b
cmake: testnative can also be built on non-Linux
2023-03-28 00:43:54 +02:00
Anonymous Maarten
c30903882b
cmake+tests: include SDL_build_config.h in select tests + add include paths
2023-03-21 23:03:02 +03:00
Anonymous Maarten
81ca9d61d6
cmake+test: add more automated tests + use properties
2023-03-21 02:19:19 +01:00
Anonymous Maarten
4a6528e3f0
testprograms: parse arguments using SDLTest_CommonState
2023-03-17 17:54:16 +01:00
Anonymous Maarten
684709a5b6
cmake: fix building testautomation without X11 support
2023-03-15 14:54:20 +01:00
Anonymous Maarten
64e242fd77
cmake: Add test resources to list of files to clean
2023-03-15 14:54:20 +01:00
Frank Praznik
cfeb663c87
tests: Add popup window test program
...
Right click to create new popup menus. Clicking over an existing popup menu will create a child menu. Left click to close all menus. Hover to display a tooltip that is the child of the window below it. Closing the application closes the root window, which should automatically destroy any open popup windows and exit gracefully.
2023-03-10 15:51:13 -08:00
Anonymous Maarten
790612f4f8
cmake: make sdltests_utils static library
2023-03-01 23:41:22 +01:00
Anonymous Maarten
dc138ee3d4
cmake: SDL3-shared target will always be a shared target
2023-02-17 23:42:03 +01:00
Anonymous Maarten
4d8a50912b
cmake: no shared SDL libraries for riscos
2023-02-16 13:59:23 -08:00
Anonymous Maarten
e203046a5c
cmake+ci: build shared and static libraries on ci
2023-02-16 13:59:23 -08:00
Anonymous Maarten
78be9eaf38
Revert "Add testcpuinfo.c"
...
This reverts commit 5888b008b1
.
2023-02-02 00:49:09 +01:00
Anonymous Maarten
5888b008b1
Add testcpuinfo.c
2023-02-01 23:34:37 +01:00
Anonymous Maarten
32e7921f98
cmake: by default, link tests to SDL3.dll on Windows
2023-01-31 01:59:21 +01:00
Anonymous Maarten
9cf34908a1
cmake: pass VERSION to project() + don't use SDL_VERSION
2023-01-31 01:59:21 +01:00
Anonymous Maarten
0ab99ffb2a
cmake: add SDL_TESTS_TIMEOUT_MULTIPLIER to account for slower machines
2023-01-10 02:39:09 +01:00
Anonymous Maarten
1d60030e84
cmake: add -Wformat when checking -Wformat-extra-args
...
The need for -Wformat when using -Wformat-extra-args was observed for
the msys2 mingw64 gcc toolchain.
2023-01-08 15:57:51 +01:00
Anonymous Maarten
373a6464c8
cmake: collect cflags in sdl-build-options and sdl-global-options
2023-01-08 15:57:51 +01:00
Sam Lantinga
1d956c2817
Rename SDL2 tests for SDL3
2023-01-03 11:54:35 -08:00
Sam Lantinga
659abc721a
SDL API renaming: SDL_gamecontroller.h
...
SDL_gamecontroller.h has been renamed SDL_gamepad.h, and all APIs have been renamed to match.
Fixes https://github.com/libsdl-org/SDL/issues/6885
2022-12-27 09:47:24 -08:00
Daniel Gibson
c3bf253b09
Remove SDL3_main from build systems, remove most of src/main/*
...
XCode is still missing, and src/main/winrt/SDL3-WinRTResource*
still need to find a new home
2022-12-15 08:01:01 -08:00
Ryan C. Gordon
a76053352c
gesture: Removed the gesture API from SDL3.
...
Fixes #6758 .
2022-12-13 14:54:37 -05:00
Sylvain
c265fb74b0
Renamed AUDIODRIVER and VIDEODRIVER hint/env to AUDIO_DRIVER and VIDEO_DRIVER
2022-12-08 09:50:09 -05:00
Sylvain Becker
92cd2c0a74
Enable creation of yuv SDL_Surfaces ( #6735 )
2022-12-02 12:53:48 -08:00
Anonymous Maarten
11ef4df207
cmake: rely on targets from the main cmake script
2022-12-01 20:32:47 +01:00
Sam Lantinga
c5790359fd
Added precompiled header support for Visual Studio and Xcode ( #6710 )
...
Fixes https://github.com/libsdl-org/SDL/issues/6704
2022-11-29 18:34:15 -08:00
Anonymous Maarten
e26e893daf
test: build + fix test/testgles2_sdf.c
2022-11-29 22:43:46 +01:00
Sam Lantinga
c2432f8d0d
Rename SDLmain to SDL_main and SDLtest to SDL_test for consistency with other SDL libraries
2022-11-28 10:57:59 -08:00
Anonymous Maarten
1fa80ca529
cmake: testevdev needs build include headers
2022-11-26 15:37:08 -08:00
Sam Lantinga
63f307fe1f
Remove SDL_config.h from the public headers
...
The SDL headers are no longer dependent on the build configuration.
Fixes https://github.com/libsdl-org/SDL/issues/6643 and https://github.com/libsdl-org/SDL/issues/6641
2022-11-26 04:48:36 -08:00
Anonymous Maarten
cd13600944
cmake: don't reset check state after pushing state
2022-11-24 23:33:54 +01:00
Ozkan Sezer
34231f5ba0
reverted opengles removal.
2022-11-23 18:50:02 +03:00
Ozkan Sezer
bd5d26071a
removed testgles.c remnants.
2022-11-22 22:14:14 +03:00
Sam Lantinga
2c4159b99a
First pass at changing SDL 2.0 to SDL 3.0
2022-11-21 20:28:58 -08:00
Anonymous Maarten
55534e277e
cmake: add time out to tests to avoid ci timeouts
2022-11-16 15:42:08 +01:00
Anonymous Maarten
a22fcf77fd
cmake: older emscripten releases have a broken FindOpenGL.cmake
...
This is fixed since 3.1.10: 485a7b4d6f (diff-034f4d123f23ec5493d0fbf28cba1c36e404a991f286c8d031a22799e4e8b0e5)
2022-11-16 15:42:08 +01:00
Anonymous Maarten
a71e558d85
cmake: testshader needs -sLEGACY_GL_EMULATION on Emscripten
2022-11-16 15:42:08 +01:00
Anonymous Maarten
cfa76973ff
cmake: FindOpenGL.cmake shipped by emscripten does not have OpenGL::GL
2022-11-16 15:42:08 +01:00
Anonymous Maarten
76e3cf3840
cmake: use custom add_sdl_test_executable macro to add test
2022-11-16 15:42:08 +01:00
Pierre Wendling
655275378d
N3DS port (squashed)
...
A dedicated renderer using Citro3D would likely allow for better
much better graphical performances.
2022-10-10 08:50:59 -07:00
Cameron Gutman
ec1137dfbd
cmake: Apply CETCOMPAT fix from ef988fe1
to tests
2022-10-09 15:19:47 -05:00
Anonymous Maarten
45da133999
cmake: don't error on apple when using deprecated declarations
2022-10-08 23:41:07 +02:00
Anonymous Maarten
274ec02581
testautomation: avoid format related warnings by using a few pragma's
...
ci: enable -Werror to a few platforms
2022-10-08 23:41:07 +02:00
Anonymous Maarten
57c886551f
automation_main.c: fix -Wformat-zero-length warning due to SDL_SetError("")
2022-10-08 23:41:07 +02:00
Cameron Gutman
2ceea46061
cmake: Enable CET compatibility for x86/x64 targets using VS 16.7+
2022-08-24 11:29:36 -07:00
Francisco Javier Trujillo Mata
46f95a7a5f
Create dummy PS2 Video driver
2022-08-02 11:40:31 -07:00
Anonymous Maarten
ac9e8691a2
cmake: only build testnative when X11 is available
2022-07-21 14:49:35 +02:00
Cameron Cawley
0a600b1df4
Merge testguid into testautomation ( #5873 )
2022-07-01 16:27:51 -07:00
Francisco Javier Trujillo Mata
84d69da4e1
Initial SDL_ps2_main implementation
2022-06-27 00:32:43 -07:00
Anonymous Maarten
965c164537
cmake: let cmake test script make use of the installed cmake scripts
2022-06-23 14:17:38 +02:00
Anonymous Maarten
3e1021239a
cmake: also add the recently-added include folder to the public interface
2022-06-22 17:04:58 +02:00
Francisco Javier Trujillo Mata
580416d3c8
Initial CMake configuration
2022-06-15 15:15:26 -07:00
Anonymous Maarten
97711e99fe
cmake: no need to explicitly add a depency (target_link_libraries does this implicitly)
2022-06-15 11:11:49 -07:00
Anonymous Maarten
ad21c70408
cmake: fix CMP0072 warning by prefering GLVND
2022-06-15 11:11:49 -07:00
Christoph Reichenbach
3a20274ddf
Refactoring: move GUID operations out of Joystick
...
- SDL_JoystickGUID -> SDL_GUID (though we retain a type alias)
- Operations for GUID <-> String ops are now in
src/SDL_guid.c and include/SDL_guid.h
- The corresponding Joystick operations delegate to SDL_guid.c
- Added test/testguid.c
2022-06-04 17:22:13 -07:00
Cameron Cawley
83ae1b4987
Convert the test executables to AIF in RISC OS CMake builds
2022-05-19 15:26:13 -07:00
pionere
c4cf63f812
improve test-configuration
...
- testkeys 'NEEDS_DISPLAY'
- 'disable' relevant tests in case DUMMY audio/video is disabled
2022-05-18 09:06:56 -07:00
Cameron Cawley
c71ee68b8a
Fix enabling tests on platforms without testnative support
2022-05-08 17:38:48 -07:00
Simon McVittie
ce502054ad
test: Install GNOME-style installed-tests metadata
...
This allows these tests to be discovered and run by
gnome-desktop-test-runner.
Signed-off-by: Simon McVittie <smcv@collabora.com>
2022-05-04 18:17:55 -07:00
Simon McVittie
38ef678990
test: Add a `make install` target for the tests
...
This makes it more convenient to compile them alongside SDL, install
them in an optional package and use them as smoke-tests or diagnostic
tools. The default installation directory is taken from GNOME's
installed-tests, which seems as good a convention as any other:
https://wiki.gnome.org/Initiatives/GnomeGoals/InstalledTests
Signed-off-by: Simon McVittie <smcv@collabora.com>
2022-05-04 18:17:55 -07:00
Simon McVittie
76a7b629bf
test: Add some common code to load test resources
...
As well as reducing duplication, this lets the tests load their resources
from the SDL_GetBasePath() on platforms that support it, which is useful
if the tests are compiled along with the rest of SDL and installed below
/usr as manual tests, similar to GNOME's installed-tests convention.
Thanks to Ozkan Sezer for the OS/2 build glue.
Co-authored-by: Ozkan Sezer <sezeroz@gmail.com>
Signed-off-by: Simon McVittie <smcv@collabora.com>
2022-05-04 18:17:55 -07:00
Simon McVittie
7d2808e30b
test: Run selected noninteractive tests at build-time
...
In Autotools, these are run by `make -C ${builddir}/test check`.
In CMake, they're run by `make -C ${builddir} test` or
`ninja -C ${builddir} test` or `ctest --test-dir ${builddir}`.
Signed-off-by: Simon McVittie <smcv@collabora.com>
2022-05-04 18:17:55 -07:00
Simon McVittie
6fc7aa28e7
cmake: Add some missing test-cases
...
These were built by Autotools but not by CMake.
Signed-off-by: Simon McVittie <smcv@collabora.com>
2022-05-04 18:17:55 -07:00
Wouter Wijsman
4cb6181808
Do not build loadso test eboot for PSP
2022-02-10 19:01:15 +01:00
Wouter Wijsman
e0c5399119
Don't make psp eboot for testoffscreen
2022-01-06 13:33:17 -08:00
Wouter Wijsman
eca198d519
Don't build an eboot for testgesture for PSP
2022-01-05 08:30:28 -08:00
Wouter Wijsman
cd6cb959c0
Only copy resources to PSP eboot directory if it exists
2022-01-05 08:30:28 -08:00
Wouter Wijsman
9d0b4d85fc
Don't build EBOOT files for all tests for PSP
2022-01-05 08:30:28 -08:00
Wouter Wijsman
b2ca62f23a
Make sure all tests have the resources they need
2022-01-05 08:30:28 -08:00
Wouter Wijsman
fcb638ff90
Copy test resources to correct directory on PSP
2022-01-03 10:39:15 -08:00
Wouter Wijsman
5e84f6384f
Rename test directories for PSP and only build PRX if asked
2022-01-03 10:39:15 -08:00
Wouter Wijsman
bf2336078c
Make tests build for PSP and make them able to launch
2022-01-03 10:39:15 -08:00
Cameron Gutman
210713a600
cmake: Work around bug in opengl32.lib detection on MSVC ARM64
2021-10-31 17:57:40 -07:00
Cameron Gutman
77141e84e0
cmake: Fix test linking with MinGW
2021-10-31 17:57:40 -07:00
Cameron Gutman
618b0d414f
cmake: Remove SDL2_test_resources dummy hack
...
It doesn't work properly on MSVC because the dummy target fails to link
2021-10-31 17:57:40 -07:00
Cameron Gutman
cd66c050fe
testsurround: Add surround sound channel tester
2021-10-30 21:26:03 -07:00