mirror of
https://github.com/nlohmann/json.git
synced 2026-06-07 13:19:43 +00:00
Merge upstream/develop into feature/locale_independent_num_to_str
This commit is contained in:
+4
-2
@@ -1,11 +1,12 @@
|
||||
# The unit test executable.
|
||||
set(JSON_UNITTEST_TARGET_NAME "json_unit")
|
||||
add_executable(${JSON_UNITTEST_TARGET_NAME}
|
||||
"src/catch.hpp"
|
||||
"thirdparty/catch/catch.hpp"
|
||||
"src/unit.cpp"
|
||||
"src/unit-algorithms.cpp"
|
||||
"src/unit-allocator.cpp"
|
||||
"src/unit-capacity.cpp"
|
||||
"src/unit-cbor.cpp"
|
||||
"src/unit-class_const_iterator.cpp"
|
||||
"src/unit-class_iterator.cpp"
|
||||
"src/unit-class_lexer.cpp"
|
||||
@@ -26,6 +27,7 @@ add_executable(${JSON_UNITTEST_TARGET_NAME}
|
||||
"src/unit-json_patch.cpp"
|
||||
"src/unit-json_pointer.cpp"
|
||||
"src/unit-modifiers.cpp"
|
||||
"src/unit-msgpack.cpp"
|
||||
"src/unit-pointer_access.cpp"
|
||||
"src/unit-readme.cpp"
|
||||
"src/unit-reference_access.cpp"
|
||||
@@ -42,7 +44,7 @@ set_target_properties(${JSON_UNITTEST_TARGET_NAME} PROPERTIES
|
||||
COMPILE_OPTIONS "$<$<CXX_COMPILER_ID:MSVC>:/EHsc;$<$<CONFIG:Release>:/Od>>"
|
||||
)
|
||||
|
||||
target_include_directories(${JSON_UNITTEST_TARGET_NAME} PRIVATE "src")
|
||||
target_include_directories(${JSON_UNITTEST_TARGET_NAME} PRIVATE "src" "thirdparty/catch")
|
||||
target_link_libraries(${JSON_UNITTEST_TARGET_NAME} ${JSON_TARGET_NAME})
|
||||
|
||||
add_test(NAME "${JSON_UNITTEST_TARGET_NAME}_default"
|
||||
|
||||
+49
-6
@@ -4,12 +4,13 @@
|
||||
|
||||
# additional flags
|
||||
CXXFLAGS += -std=c++11 -Wall -Wextra -pedantic -Weffc++ -Wcast-align -Wcast-qual -Wno-ctor-dtor-privacy -Wdisabled-optimization -Wformat=2 -Winit-self -Wmissing-declarations -Wmissing-include-dirs -Wold-style-cast -Woverloaded-virtual -Wredundant-decls -Wshadow -Wsign-conversion -Wsign-promo -Wstrict-overflow=5 -Wswitch -Wundef -Wno-unused -Wnon-virtual-dtor -Wreorder -Wdeprecated -Wno-float-equal
|
||||
CPPFLAGS += -I ../src -I .
|
||||
CPPFLAGS += -I ../src -I . -I thirdparty/catch
|
||||
|
||||
SOURCES = src/unit.cpp \
|
||||
src/unit-algorithms.cpp \
|
||||
src/unit-allocator.cpp \
|
||||
src/unit-capacity.cpp \
|
||||
src/unit-cbor.cpp \
|
||||
src/unit-class_const_iterator.cpp \
|
||||
src/unit-class_iterator.cpp \
|
||||
src/unit-class_lexer.cpp \
|
||||
@@ -30,6 +31,7 @@ SOURCES = src/unit.cpp \
|
||||
src/unit-json_patch.cpp \
|
||||
src/unit-json_pointer.cpp \
|
||||
src/unit-modifiers.cpp \
|
||||
src/unit-msgpack.cpp \
|
||||
src/unit-pointer_access.cpp \
|
||||
src/unit-readme.cpp \
|
||||
src/unit-reference_access.cpp \
|
||||
@@ -40,15 +42,56 @@ SOURCES = src/unit.cpp \
|
||||
|
||||
OBJECTS = $(SOURCES:.cpp=.o)
|
||||
|
||||
all: json_unit
|
||||
TESTCASES = $(patsubst src/unit-%.cpp,test-%,$(wildcard src/unit-*.cpp))
|
||||
|
||||
json_unit: $(OBJECTS) ../src/json.hpp src/catch.hpp
|
||||
##############################################################################
|
||||
# main rules
|
||||
##############################################################################
|
||||
|
||||
all: $(TESTCASES)
|
||||
|
||||
clean:
|
||||
rm -fr json_unit $(OBJECTS) $(SOURCES:.cpp=.gcno) $(SOURCES:.cpp=.gcda) $(TESTCASES) parse_afl_fuzzer parse_cbor_fuzzer parse_msgpack_fuzzer
|
||||
|
||||
##############################################################################
|
||||
# single test file
|
||||
##############################################################################
|
||||
|
||||
json_unit: $(OBJECTS) ../src/json.hpp thirdparty/catch/catch.hpp
|
||||
@echo "[CXXLD] $@"
|
||||
@$(CXX) $(CXXFLAGS) $(LDFLAGS) $(OBJECTS) -o $@
|
||||
|
||||
%.o: %.cpp ../src/json.hpp src/catch.hpp
|
||||
%.o: %.cpp ../src/json.hpp thirdparty/catch/catch.hpp
|
||||
@echo "[CXX] $@"
|
||||
@$(CXX) $(CXXFLAGS) $(CPPFLAGS) -c $< -o $@
|
||||
|
||||
clean:
|
||||
rm -fr json_unit $(OBJECTS) $(SOURCES:.cpp=.gcno) $(SOURCES:.cpp=.gcda)
|
||||
|
||||
##############################################################################
|
||||
# individual test cases
|
||||
##############################################################################
|
||||
|
||||
test-%: src/unit-%.cpp ../src/json.hpp thirdparty/catch/catch.hpp
|
||||
@echo "[CXXLD] $@"
|
||||
@$(CXX) $(CXXFLAGS) $(CPPFLAGS) $(LDFLAGS) -DCATCH_CONFIG_MAIN $< -o $@
|
||||
|
||||
TEST_PATTERN = "*"
|
||||
TEST_PREFIX = ""
|
||||
check: $(TESTCASES)
|
||||
@cd .. ; for testcase in $(TESTCASES); do echo "Executing $$testcase..."; $(TEST_PREFIX)test/$$testcase $(TEST_PATTERN) || exit 1; done
|
||||
|
||||
|
||||
##############################################################################
|
||||
# fuzzer
|
||||
##############################################################################
|
||||
|
||||
FUZZER_ENGINE = src/fuzzer-driver_afl.cpp
|
||||
fuzzers: parse_afl_fuzzer parse_cbor_fuzzer parse_msgpack_fuzzer
|
||||
|
||||
parse_afl_fuzzer:
|
||||
$(CXX) $(CXXFLAGS) $(CPPFLAGS) $(FUZZER_ENGINE) src/fuzzer-parse_json.cpp -o $@
|
||||
|
||||
parse_cbor_fuzzer:
|
||||
$(CXX) $(CXXFLAGS) $(CPPFLAGS) $(FUZZER_ENGINE) src/fuzzer-parse_cbor.cpp -o $@
|
||||
|
||||
parse_msgpack_fuzzer:
|
||||
$(CXX) $(CXXFLAGS) $(CPPFLAGS) $(FUZZER_ENGINE) src/fuzzer-parse_msgpack.cpp -o $@
|
||||
|
||||
@@ -0,0 +1 @@
|
||||
亄��������������
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -0,0 +1 @@
|
||||
”{˙˙˙˙˙˙˙˙˙’˙˙˙˙˙˙˙˙úúúúúúúúúúúúetú
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -0,0 +1 @@
|
||||
¡hglossary¢hGlossDiv¢iGlossList¡jGlossEntry§hGlossDef¢lGlossSeeAlso‚cGMLcXMLdparaxHA meta-markup language, used to create markup languages such as DocBook.hGlossSeefmarkupgAcronymdSGMLiGlossTermx$Standard Generalized Markup LanguagefAbbrevmISO 8879:1986fSortAsdSGMLbIDdSGMLetitleaSetitlepexample glossary
|
||||
Binary file not shown.
@@ -0,0 +1 @@
|
||||
¡dmenu£epopup¡hmenuitemƒ¢gonclicknCreateNewDoc()evaluecNew¢gonclickiOpenDoc()evaluedOpen¢gonclickjCloseDoc()evalueeClosebiddfileevaluedFile
|
||||
@@ -0,0 +1 @@
|
||||
�menu�popup�menuitem�吶nclick哽reateNewDoc()史alueΛew�onclick呢penDoc()史alue力pen�onclick杭loseDoc()史alue丘lose█d口ile史alue了ile
|
||||
@@ -0,0 +1 @@
|
||||
¡fwidget¤edebugbondtext¨gvOffsetdestyledbolddnameetext1ghOffsetúionMouseUpx)sun1.opacity = (sun1.opacity / 100) * 90;ddatajClick Hereialignmentfcenterdsize$fwindow¤ewidthôfheightôdnamekmain_windowetitlexSample Konfabulator Widgeteimage¥gvOffsetúcsrcnImages/Sun.pngialignmentfcenterdnamedsun1ghOffsetú
|
||||
Binary file not shown.
@@ -0,0 +1,4 @@
|
||||
¡gweb-app£oservlet-mapping¥jcofaxToolsh/tools/*hcofaxCDSa/kfileServleti/static/*jcofaxAdminh/admin/*jcofaxEmails/cofaxutil/aemail/*ftaglib¢otaglib-locationw/WEB-INF/tlds/cofax.tldjtaglib-uriicofax.tldgservlet…£lservlet-namehcofaxCDSjinit-param¸*ocachePagesStoredxsearchEngineListTemplatexforSearchEnginesList.htmxconfigGlossary:adminEmailmksm@pobox.comlmaxUrlLengthôrdataStoreTestQueryx"SET NOCOUNT ON;select test='test';sdefaultFileTemplatesarticleTemplate.htmpdataStoreLogFilex$/usr/local/tomcat/logs/datastore.logstemplateLoaderClassxorg.cofax.FilesTemplateLoaderndataStoreClassvorg.cofax.SqlDataStorepredirectionClassxorg.cofax.SqlRedirectionttemplateOverridePath`scacheTemplatesStore2ldataStoreUrlx;jdbc:microsoft:sqlserver://LOCALHOST:1433;DatabaseName=goonxsearchEngineFileTemplatetforSearchEngines.htmocachePagesTrackÈucachePackageTagsStoreÈmdataStoreNameecofaxqdataStorePasswordrdataStoreTestQueryfuseJSPôsdefaultListTemplateplistTemplate.htmxconfigGlossary:poweredByeCofaxmdataStoreUserbsaojspListTemplateplistTemplate.jspojspFileTemplatesarticleTemplate.jspqdataStoreMaxConnsdscachePagesDirtyRead
|
||||
qcachePagesRefresh
|
||||
scacheTemplatesTrackdwdataStoreConnUsageLimitdxconfigGlossary:installationAtpPhiladelphia, PAtsearchEngineRobotsDbqWEB-INF/robots.dbvtemplateProcessorClassxorg.cofax.WysiwygTemplatewcachePackageTagsRefresh<xconfigGlossary:staticPatho/content/staticltemplatePathitemplatesluseDataStoreõucacheTemplatesRefreshodataStoreDriverx,com.microsoft.jdbc.sqlserver.SQLServerDriverxconfigGlossary:poweredByIconq/images/cofax.gifucachePackageTagsTrackÈqdataStoreLogLeveledebugrdataStoreInitConns
|
||||
mservlet-classxorg.cofax.cds.CDSServlet£lservlet-namejcofaxEmailjinit-param¢pmailHostOverrideemail2hmailHostemail1mservlet-classxorg.cofax.cds.EmailServlet¢lservlet-namejcofaxAdminmservlet-classxorg.cofax.cds.AdminServlet¢lservlet-namekfileServletmservlet-classxorg.cofax.cds.FileServlet£lservlet-namejcofaxToolsjinit-paramklogLocationx%/usr/local/tomcat/logs/CofaxTools.logrfileTransferFolderx4/usr/local/tomcat/webapps/content/fileTransferFoldercloggdataLogodataLogLocationx"/usr/local/tomcat/logs/dataLog.logladminGroupIDmlookInContextoremovePageCachex%/content/admin/remove?cache=pages&id=sremoveTemplateCachex)/content/admin/remove?cache=templates&id=jlogMaxSize`ndataLogMaxSize`jbetaServerõltemplatePathotoolstemplates/mservlet-classxorg.cofax.cms.CofaxToolsServlet
|
||||
Binary file not shown.
@@ -0,0 +1 @@
|
||||
¡dmenu¢fheaderjSVG Viewereitems–¡biddOpen¢bidgOpenNewelabelhOpen Newö¢bidfZoomInelabelgZoom In¢bidgZoomOutelabelhZoom Out¢bidlOriginalViewelabelmOriginal Viewö¡bidgQuality¡bidePause¡biddMuteö¢biddFindelabelgFind...¢bidiFindAgainelabeljFind Again¡biddCopy¢bidiCopyAgainelabeljCopy Again¢bidgCopySVGelabelhCopy SVG¢bidgViewSVGelabelhView SVG¢bidjViewSourceelabelkView Source¢bidfSaveAselabelgSave Asö¡biddHelp¢bideAboutelabelxAbout Adobe CVG Viewer...
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -0,0 +1 @@
|
||||
��
|
||||
@@ -0,0 +1 @@
|
||||
‘À
|
||||
@@ -0,0 +1 @@
|
||||
��
|
||||
@@ -0,0 +1 @@
|
||||
��
|
||||
@@ -0,0 +1 @@
|
||||
��
|
||||
@@ -0,0 +1 @@
|
||||
‘В
|
||||
Binary file not shown.
Binary file not shown.
@@ -0,0 +1 @@
|
||||
�cfoo
|
||||
@@ -0,0 +1 @@
|
||||
‘£foo
|
||||
@@ -0,0 +1 @@
|
||||
�
|
||||
@@ -0,0 +1 @@
|
||||
�
|
||||
@@ -0,0 +1 @@
|
||||
�
|
||||
@@ -0,0 +1 @@
|
||||
�
|
||||
Binary file not shown.
Binary file not shown.
@@ -0,0 +1 @@
|
||||
¡cfoocbar
|
||||
@@ -0,0 +1 @@
|
||||
�£foo£bar
|
||||
@@ -0,0 +1 @@
|
||||
¢aaöcfoocbar
|
||||
@@ -0,0 +1 @@
|
||||
‚¡aÀ£foo£bar
|
||||
@@ -0,0 +1 @@
|
||||
�
|
||||
@@ -0,0 +1 @@
|
||||
��
|
||||
@@ -0,0 +1 @@
|
||||
�:���
|
||||
Binary file not shown.
@@ -0,0 +1 @@
|
||||
�;"τ}ι�
|
||||
@@ -0,0 +1 @@
|
||||
������~�
|
||||
@@ -0,0 +1 @@
|
||||
�;�������
|
||||
Binary file not shown.
@@ -0,0 +1 @@
|
||||
�
|
||||
@@ -0,0 +1 @@
|
||||
�
|
||||
@@ -0,0 +1 @@
|
||||
����
|
||||
@@ -0,0 +1 @@
|
||||
𤥵���
|
||||
@@ -0,0 +1 @@
|
||||
�����
|
||||
@@ -0,0 +1 @@
|
||||
懳����
|
||||
@@ -0,0 +1 @@
|
||||
�"τ}ι�
|
||||
@@ -0,0 +1 @@
|
||||
‘Ο"τ}ι�
|
||||
@@ -0,0 +1 @@
|
||||
��������
|
||||
@@ -0,0 +1 @@
|
||||
‘Ο�������
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -0,0 +1 @@
|
||||
��?���n��
|
||||
@@ -0,0 +1 @@
|
||||
��?鸚�n��
|
||||
@@ -0,0 +1 @@
|
||||
侞矿纼n棈
|
||||
@@ -0,0 +1 @@
|
||||
懰矿纼n棈
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -0,0 +1 @@
|
||||
�ϋο������
|
||||
@@ -0,0 +1 @@
|
||||
‘Λο������
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -0,0 +1 @@
|
||||
�9ケ 脉�
|
||||
@@ -0,0 +1 @@
|
||||
騨9ケ 脉�
|
||||
@@ -0,0 +1 @@
|
||||
ЃыF/)До±Uе
|
||||
@@ -0,0 +1 @@
|
||||
‘ЛF/)До±Uе
|
||||
@@ -0,0 +1 @@
|
||||
ЃыF/)До±Uе
|
||||
@@ -0,0 +1 @@
|
||||
‘ЛF/)До±Uе
|
||||
Binary file not shown.
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user