Commit 1362d9d2 authored by Nikolai Kosjar's avatar Nikolai Kosjar

CppTools: Fix test_modelmanager_defines_per_project

The example project parts had no project file set and thus the "right"
project part could not be determined in cppeditor.cpp:718.

Change-Id: I088571e9d3c3c8790670bbdd8e68190835a85ad5
Reviewed-by: default avatarErik Verbruggen <erik.verbruggen@digia.com>
parent 6de1958a
......@@ -806,6 +806,7 @@ void CppToolsPlugin::test_modelmanager_defines_per_project()
Project *project = helper.createProject(_("test_modelmanager_defines_per_project"));
ProjectPart::Ptr part1(new ProjectPart);
part1->projectFile = QLatin1String("project1.projectfile");
part1->files.append(ProjectFile(main1File, ProjectFile::CXXSource));
part1->files.append(ProjectFile(header, ProjectFile::CXXHeader));
part1->cxxVersion = ProjectPart::CXX11;
......@@ -814,6 +815,7 @@ void CppToolsPlugin::test_modelmanager_defines_per_project()
part1->includePaths = QStringList() << testDataDirectory.includeDir(false);
ProjectPart::Ptr part2(new ProjectPart);
part2->projectFile = QLatin1String("project1.projectfile");
part2->files.append(ProjectFile(main2File, ProjectFile::CXXSource));
part2->files.append(ProjectFile(header, ProjectFile::CXXHeader));
part2->cxxVersion = ProjectPart::CXX11;
......@@ -878,6 +880,7 @@ void CppToolsPlugin::test_modelmanager_defines_per_project_pch()
Project *project = helper.createProject(_("test_modelmanager_defines_per_project_pch"));
ProjectPart::Ptr part1(new ProjectPart);
part1->projectFile = QLatin1String("project1.projectfile");
part1->files.append(ProjectFile(main1File, ProjectFile::CXXSource));
part1->files.append(ProjectFile(header, ProjectFile::CXXHeader));
part1->cxxVersion = ProjectPart::CXX11;
......@@ -886,6 +889,7 @@ void CppToolsPlugin::test_modelmanager_defines_per_project_pch()
part1->includePaths = QStringList() << testDataDirectory.includeDir(false);
ProjectPart::Ptr part2(new ProjectPart);
part2->projectFile = QLatin1String("project2.projectfile");
part2->files.append(ProjectFile(main2File, ProjectFile::CXXSource));
part2->files.append(ProjectFile(header, ProjectFile::CXXHeader));
part2->cxxVersion = ProjectPart::CXX11;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment