File: tst_shell_mac.cpp

package info (click to toggle)
neovim-qt 0.2.19-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 3,808 kB
  • sloc: cpp: 45,441; python: 234; makefile: 24; sh: 19; xml: 5
file content (31 lines) | stat: -rw-r--r-- 709 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
#include "tst_shell.h"

#include <QTest>

namespace NeovimQt {

QClipboard::Mode GetClipboardMode(char /*reg*/) noexcept
{
	return QClipboard::Clipboard;
}

QString GetPlatformTestFont() noexcept
{
	return QStringLiteral("Monaco");
}

QStringList BinaryAndArgumentsNoForkWithCommand(const QString& command) noexcept
{
	return { NVIM_QT_BINARY, "--nofork", "--",  "-c", command };
}

void AddPlatformSpecificExitCodeCases() noexcept
{
	// On UNIX-like operating systems, the child exit code is represented as a
	// 8-bit integer. Therefore 256 overflows and becomes 0.
	// Reference: man for wait(2).
	QTest::newRow("Exit Code Overflow: 256cq")
		<< 256 << 0 << QByteArray("256cq");
}

} // namespace NeovimQt