mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-13 09:47:58 -06:00
Add the full source of BambuStudio
using version 1.0.10
This commit is contained in:
parent
30bcadab3e
commit
1555904bef
3771 changed files with 1251328 additions and 0 deletions
60
tests/slic3rutils/slic3rutils_tests_main.cpp
Normal file
60
tests/slic3rutils/slic3rutils_tests_main.cpp
Normal file
|
@ -0,0 +1,60 @@
|
|||
#include <catch_main.hpp>
|
||||
|
||||
#include "slic3r/Utils/Http.hpp"
|
||||
|
||||
TEST_CASE("Check SSL certificates paths", "[Http][NotWorking]") {
|
||||
|
||||
Slic3r::Http g = Slic3r::Http::get("https://github.com/");
|
||||
|
||||
unsigned status = 0;
|
||||
g.on_error([&status](std::string, std::string, unsigned http_status) {
|
||||
status = http_status;
|
||||
});
|
||||
|
||||
g.on_complete([&status](std::string /* body */, unsigned http_status){
|
||||
status = http_status;
|
||||
});
|
||||
|
||||
g.perform_sync();
|
||||
|
||||
REQUIRE(status == 200);
|
||||
}
|
||||
|
||||
TEST_CASE("Http digest authentication", "[Http][NotWorking]") {
|
||||
Slic3r::Http g = Slic3r::Http::get("https://jigsaw.w3.org/HTTP/Digest/");
|
||||
|
||||
g.auth_digest("guest", "guest");
|
||||
|
||||
unsigned status = 0;
|
||||
g.on_error([&status](std::string, std::string, unsigned http_status) {
|
||||
status = http_status;
|
||||
});
|
||||
|
||||
g.on_complete([&status](std::string /* body */, unsigned http_status){
|
||||
status = http_status;
|
||||
});
|
||||
|
||||
g.perform_sync();
|
||||
|
||||
REQUIRE(status == 200);
|
||||
}
|
||||
|
||||
TEST_CASE("Http basic authentication", "[Http][NotWorking]") {
|
||||
Slic3r::Http g = Slic3r::Http::get("https://jigsaw.w3.org/HTTP/Basic/");
|
||||
|
||||
g.auth_basic("guest", "guest");
|
||||
|
||||
unsigned status = 0;
|
||||
g.on_error([&status](std::string, std::string, unsigned http_status) {
|
||||
status = http_status;
|
||||
});
|
||||
|
||||
g.on_complete([&status](std::string /* body */, unsigned http_status){
|
||||
status = http_status;
|
||||
});
|
||||
|
||||
g.perform_sync();
|
||||
|
||||
REQUIRE(status == 200);
|
||||
}
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue