Closed rejkid closed 12 months ago
Yes
I am getting this output with the input ex27j.txt
C:\ScheduleMeWorkspace\ScheduleMeBackEnd>C:\ScheduleMeWorkspace\ScheduleMeBackEnd\Agents2Tasks.exe ./Upload/ex27j.txt ./Upload/a2t_result.txt terminate called after throwing an instance of 'std::runtime_error' what(): 16 1 unit test failed
Here is the unit test code
Run under the debugger and see what the difference between expected and result is
The unit tests do not depend on the input. A unit test failure indicates a build error. My best guess is that you are not building from the latest commit. Please post a screenshot of the github desktop application. It should look like this:
#
You need to show the history
That looks good.
What do you get from the debugger?
You should also post the complete build log.
Executing task: C:\Users\James\code_ext\msys64\mingw64\bin\mingw32-make.exe -f .vscode/makefile a2t
g++ ./src/main.cpp \
-c -o .vscode/obj/main.o -I./include -I../raven-set -std=c++17 -g -D_mingw_
g++ ./src/input.cpp \
-c -o .vscode/obj/input.o -I./include -I../raven-set -std=c++17 -g -D_mingw_
g++ ./src/cAgent.cpp \
-c -o .vscode/obj/cAgent.o -I./include -I../raven-set -std=c++17 -g -D_mingw_
g++ ./src/cTask.cpp \
-c -o .vscode/obj/cTask.o -I./include -I../raven-set -std=c++17 -g -D_mingw_
g++ ./src/cSlot.cpp \
-c -o .vscode/obj/cSlot.o -I./include -I../raven-set -std=c++17 -g -D_mingw_
g++ ./src/cAssign.cpp \
-c -o .vscode/obj/cAssign.o -I./include -I../raven-set -std=c++17 -g -D_mingw_
g++ ./src/unitTest.cpp \
-c -o .vscode/obj/unitTest.o -I./include -I../raven-set -std=c++17 -g -D_mingw_
g++ -g \
-o bin/Agents2Tasks.exe .vscode/obj/main.o .vscode/obj/input.o .vscode/obj/cAgent.o .vscode/obj/cTask.o .vscode/obj/cSlot.o .vscode/obj/cAssign.o .vscode/obj/unitTest.o \
-static-libstdc++ -static-libgcc -static -lComctl32 -lgdiplus -lgdi32 -lcomdlg32 -lstdc++fs
* Terminal will be reused by tasks, press any key to close it.
I can reproduce this!
I don't know how to run debugger for cpp in VC. I have never done it before
Press key F5 to run under debugger
I did and I get this dialog box: ... I pressed "Install cppdbg Extension" and it says "No extension found"
You will have to ask a VSCODE forum about that
Cause: std::stable_sort()
appears not to be working as expected. It seems that the order of equivalent agents is not stable, but random.
is it fixable ?
I have labelled this issue 'accepted' That means I am working on it. You can find the meaning of any label by hovering the mouse cursor over the label.
The Agents2Tasks.exe is passing all unit tests for input file ex27j.txt and generates the output file.
Does Agents2Tasks.exe replace Agents2TasksConsole.exe I can't see the target in makefile to build console app