Skip to content

Commit d6c8e97

Browse files
Runner for all apltform
1 parent 311f266 commit d6c8e97

1 file changed

Lines changed: 8 additions & 6 deletions

File tree

.github/workflows/dotnet-tests.yml

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -87,20 +87,22 @@ jobs:
8787
run: |
8888
# Set target path within the .NET build output
8989
DEST_PATH="backend/CaseConversionAPI/tests/DotNetTests/bin/Release/net8.0/"
90-
mkdir -p $DEST_PATH
90+
mkdir -p "$DEST_PATH"
9191
92-
# Find the library based on platform extension
92+
# Search recursively from the build root for the platform-specific binary
9393
if [ "${{ runner.os }}" == "Linux" ]; then
94-
LIB_FILE=$(find backend/CaseConversionAPI/CppLib/build -name "libProcessStringDLL.so" | head -n 1)
94+
LIB_FILE=$(find backend/CaseConversionAPI/CppLib/build -type f -name "libProcessStringDLL.so" | head -n 1)
9595
elif [ "${{ runner.os }}" == "macOS" ]; then
96-
LIB_FILE=$(find backend/CaseConversionAPI/CppLib/build -name "libProcessStringDLL.dylib" | head -n 1)
96+
LIB_FILE=$(find backend/CaseConversionAPI/CppLib/build -type f -name "libProcessStringDLL.dylib" | head -n 1)
9797
elif [ "${{ runner.os }}" == "Windows" ]; then
98-
# MSVC often puts binaries in /Release/ or /Debug/ subfolders
99-
LIB_FILE=$(find backend/CaseConversionAPI/CppLib/build -name "ProcessStringDLL.dll" | head -n 1)
98+
# MSVC often nests binaries in build/Release/ or build/bin/Release
99+
LIB_FILE=$(find backend/CaseConversionAPI/CppLib/build -type f -name "ProcessStringDLL.dll" | head -n 1)
100100
fi
101101
102102
if [ -z "$LIB_FILE" ]; then
103103
echo "[ERROR] Native library not found for ${{ runner.os }}"
104+
# Debug: List the build directory to see where the file actually is
105+
ls -R backend/CaseConversionAPI/CppLib/build
104106
exit 1
105107
fi
106108

0 commit comments

Comments
 (0)