[ Web Proxy ]
URL:
Viewing: https://raw.githubusercontent.com/livecodeali/livecode/develop/engine/test/test_lextable.cpp [Back]  [Original]

/* Copyright (C) 2003-2015 LiveCode Ltd.

This file is part of LiveCode.

LiveCode is free software; you can redistribute it and/or modify it under
the terms of the GNU General Public License v3 as published by the Free
Software Foundation.

LiveCode is distributed in the hope that it will be useful, but WITHOUT ANY
WARRANTY; without even the implied warranty of MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
for more details.

You should have received a copy of the GNU General Public License
along with LiveCode.  If not see .  */

#include "gtest/gtest.h"

#include "prefix.h"
#include "parsedef.h"
#include "scriptpt.h"

TEST(lextable, constant_table)
//
// Checks that the entries of constant_table are in alphabetical order.
//
{
    extern const Cvalue *constant_table;
	extern const uint4 constant_table_size;

	ASSERT_GE(constant_table_size, (unsigned)1);

	for(uint4 i = 0; i < constant_table_size - 1; i++) {
		EXPECT_LT(strcmp(constant_table[i].token, constant_table[i+1].token), 0)
			

Web Proxy Viewer  |  New URL  |  Original Page