Skip to content
This repository was archived by the owner on Jul 15, 2023. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,16 +1,5 @@
// CodeContracts
//
// Copyright (c) Microsoft Corporation
//
// All rights reserved.
//
// MIT License
//
// Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED *AS IS*, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
// Copyright (c) Microsoft. All rights reserved.
// Licensed under the MIT license. See LICENSE file in the project root for full license information.

using System.Reflection;
using System.Runtime.CompilerServices;
Expand All @@ -24,7 +13,7 @@
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("Microsoft")]
[assembly: AssemblyProduct("ClousotCacheTests")]
[assembly: AssemblyCopyright("Copyright © Microsoft 2010")]
[assembly: AssemblyCopyright("Copyright \u00A9 Microsoft 2010")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]

Expand Down
84 changes: 37 additions & 47 deletions Microsoft.Research/RegressionTest/ClousotCacheTests/Sources/DB.cs
Original file line number Diff line number Diff line change
@@ -1,67 +1,57 @@
// CodeContracts
//
// Copyright (c) Microsoft Corporation
//
// All rights reserved.
//
// MIT License
//
// Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED *AS IS*, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
// Copyright (c) Microsoft. All rights reserved.
// Licensed under the MIT license. See LICENSE file in the project root for full license information.

using System;
using System.Diagnostics.Contracts;
using Microsoft.Research.ClousotRegression;

// Stressing the function name maximum length that can be stored in the DB

namespace Caching
{
using A = IAmANamespaceWithARelativelyLongNameContainingAGenericClassWithARelativelyLongName.IAmAGenericClassWithARelativelyLongName<object, object>;
namespace IAmANamespaceWithARelativelyLongNameContainingAGenericClassWithARelativelyLongName
{
class IAmAGenericClassWithARelativelyLongName<T1, T2> { }
}
namespace IAmANamespaceWithARelativelyLongNameContainingAGenericClassWithARelativelyLongName
{
using B = IAmAGenericClassWithARelativelyLongName<A, A>;
namespace IAmANamespaceWithARelativelyLongNameContainingAGenericClassWithARelativelyLongName2
using A = IAmANamespaceWithARelativelyLongNameContainingAGenericClassWithARelativelyLongName.IAmAGenericClassWithARelativelyLongName<object, object>;
namespace IAmANamespaceWithARelativelyLongNameContainingAGenericClassWithARelativelyLongName
{
internal class IAmAGenericClassWithARelativelyLongName<T1, T2> { }
}
namespace IAmANamespaceWithARelativelyLongNameContainingAGenericClassWithARelativelyLongName
{
using C = IAmAGenericClassWithARelativelyLongName<B, B>;
namespace IAmANamespaceWithARelativelyLongNameContainingAGenericClassWithARelativelyLongName3
{
using D = IAmAGenericClassWithARelativelyLongName<C, C>;
namespace IAmANamespaceWithARelativelyLongNameContainingAGenericClassWithARelativelyLongName4
using B = IAmAGenericClassWithARelativelyLongName<A, A>;
namespace IAmANamespaceWithARelativelyLongNameContainingAGenericClassWithARelativelyLongName2
{
using E = IAmAGenericClassWithARelativelyLongName<D, D>;
namespace IAmANamespaceWithARelativelyLongNameContainingAGenericClassWithARelativelyLongName5
{
using F = IAmAGenericClassWithARelativelyLongName<E, E>;
namespace IAmANamespaceWithARelativelyLongNameContainingAGenericClassWithARelativelyLongName6
using C = IAmAGenericClassWithARelativelyLongName<B, B>;
namespace IAmANamespaceWithARelativelyLongNameContainingAGenericClassWithARelativelyLongName3
{
using G = IAmAGenericClassWithARelativelyLongName<F, F>;
using D = IAmAGenericClassWithARelativelyLongName<C, C>;
namespace IAmANamespaceWithARelativelyLongNameContainingAGenericClassWithARelativelyLongName4
{
using E = IAmAGenericClassWithARelativelyLongName<D, D>;
namespace IAmANamespaceWithARelativelyLongNameContainingAGenericClassWithARelativelyLongName5
{
using F = IAmAGenericClassWithARelativelyLongName<E, E>;
namespace IAmANamespaceWithARelativelyLongNameContainingAGenericClassWithARelativelyLongName6
{
using G = IAmAGenericClassWithARelativelyLongName<F, F>;

class IAmAStaticClassWithARelativelyLongName
{
[ClousotRegressionTest]
internal class IAmAStaticClassWithARelativelyLongName
{
[ClousotRegressionTest]
#if FIRST
[RegressionOutcome("No entry found in the cache")]
[RegressionOutcome("No entry found in the cache")]
#else
[RegressionOutcome("No entry found in the cache")] // we won't save this as it is too long
// [RegressionOutcome("An entry has been found in the cache")]
[RegressionOutcome("No entry found in the cache")] // we won't save this as it is too long
// [RegressionOutcome("An entry has been found in the cache")]
#endif
public static void IAmAFunctionWithARelativelyLongNameUsingTheGenericClassWithARelativelyLongName(G x)
{
Contract.Requires(x != null);
Console.WriteLine(x);
public static void IAmAFunctionWithARelativelyLongNameUsingTheGenericClassWithARelativelyLongName(G x)
{
Contract.Requires(x != null);
Console.WriteLine(x);
}
}
}
}
}
}
}
}
}
}
}
}
}
Loading