(T val1, T2 val2)
14 | {
15 | return val1?.ToString() + " " + val2?.ToString();
16 | }
17 | }
18 | }
--------------------------------------------------------------------------------
/test/BlazorWorkbench/Data/WeatherForecast.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | namespace BlazorWorkbench.Data
4 | {
5 | public class WeatherForecast
6 | {
7 | public DateTime Date { get; set; }
8 |
9 | public int TemperatureC { get; set; }
10 |
11 | public int TemperatureF => 320 + (int)(TemperatureC / 0.5556);
12 |
13 | public string Summary { get; set; }
14 | }
15 | }
--------------------------------------------------------------------------------
/test/BlazorWorkbench/Pages/Company.cs:
--------------------------------------------------------------------------------
1 | namespace Models.Medew
2 | {
3 | public class Company
4 | {
5 | public int CompanyID { get; set; }
6 | public string Name { get; set; }
7 |
8 | }
9 |
10 | static class Extensions
11 | {
12 | public static string Modify(this string val)
13 | {
14 | return val;
15 | }
16 | }
17 | }
--------------------------------------------------------------------------------
/test/BlazorWorkbench/Pages/TestPage.Stuff.cs:
--------------------------------------------------------------------------------
1 | namespace Models.Account
2 | {
3 |
4 | }
--------------------------------------------------------------------------------
/test/BlazorWorkbench/Shared/MainLayout.razor:
--------------------------------------------------------------------------------
1 | @inherits LayoutComponentBase
2 |
3 |
6 |
7 |
8 |
11 |
12 |
13 | @Body
14 |
15 |
--------------------------------------------------------------------------------
/test/BlazorWorkbench/Shared/SurveyPrompt.razor:
--------------------------------------------------------------------------------
1 |
2 |
3 |
@Title
4 |
5 |
6 | Please take our
7 | brief survey
8 |
9 | and tell us what you think.
10 |
11 |
12 | @code {
13 | // Demonstrates how a parent component can supply parameters
14 | [Parameter]
15 | public string Title { get; set; }
16 |
17 | }
--------------------------------------------------------------------------------
/test/BlazorWorkbench/_Imports.razor:
--------------------------------------------------------------------------------
1 | @using System.Net.Http
2 | @using Microsoft.AspNetCore.Authorization
3 | @using Microsoft.AspNetCore.Components.Authorization
4 | @using Microsoft.AspNetCore.Components.Forms
5 | @using Microsoft.AspNetCore.Components.Routing
6 | @using Microsoft.AspNetCore.Components.Web
7 | @using Microsoft.JSInterop
8 | @using BlazorWorkbench
9 | @using BlazorWorkbench.Shared
--------------------------------------------------------------------------------
/test/BlazorWorkbench/appsettings.Development.json:
--------------------------------------------------------------------------------
1 | {
2 | "DetailedErrors": true,
3 | "Logging": {
4 | "LogLevel": {
5 | "Default": "Information",
6 | "Microsoft": "Warning",
7 | "Microsoft.Hosting.Lifetime": "Information"
8 | }
9 | }
10 | }
11 |
--------------------------------------------------------------------------------
/test/BlazorWorkbench/appsettings.json:
--------------------------------------------------------------------------------
1 | {
2 | "Logging": {
3 | "LogLevel": {
4 | "Default": "Information",
5 | "Microsoft": "Warning",
6 | "Microsoft.Hosting.Lifetime": "Information"
7 | }
8 | },
9 | "AllowedHosts": "*"
10 | }
11 |
--------------------------------------------------------------------------------
/test/BlazorWorkbench/livesharphandler.json.cmd:
--------------------------------------------------------------------------------
1 | start chrome https://www.google.com/
--------------------------------------------------------------------------------
/test/BlazorWorkbench/wwwroot/css/open-iconic/font/fonts/open-iconic.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ionoy/LiveSharp/754823359f8af8bbee98d5a349b7068e79c84102/test/BlazorWorkbench/wwwroot/css/open-iconic/font/fonts/open-iconic.eot
--------------------------------------------------------------------------------
/test/BlazorWorkbench/wwwroot/css/open-iconic/font/fonts/open-iconic.otf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ionoy/LiveSharp/754823359f8af8bbee98d5a349b7068e79c84102/test/BlazorWorkbench/wwwroot/css/open-iconic/font/fonts/open-iconic.otf
--------------------------------------------------------------------------------
/test/BlazorWorkbench/wwwroot/css/open-iconic/font/fonts/open-iconic.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ionoy/LiveSharp/754823359f8af8bbee98d5a349b7068e79c84102/test/BlazorWorkbench/wwwroot/css/open-iconic/font/fonts/open-iconic.ttf
--------------------------------------------------------------------------------
/test/BlazorWorkbench/wwwroot/css/open-iconic/font/fonts/open-iconic.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ionoy/LiveSharp/754823359f8af8bbee98d5a349b7068e79c84102/test/BlazorWorkbench/wwwroot/css/open-iconic/font/fonts/open-iconic.woff
--------------------------------------------------------------------------------
/test/BlazorWorkbench/wwwroot/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ionoy/LiveSharp/754823359f8af8bbee98d5a349b7068e79c84102/test/BlazorWorkbench/wwwroot/favicon.ico
--------------------------------------------------------------------------------
/test/LiveBlazorWorkbench/App.razor:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Sorry, there's nothing at this address.
8 |
9 |
10 |
--------------------------------------------------------------------------------
/test/LiveBlazorWorkbench/Data/WeatherForecast.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | namespace LiveBlazorWorkbench.Data
4 | {
5 | public class WeatherForecast
6 | {
7 | public DateTime Date { get; set; }
8 |
9 | public int TemperatureC { get; set; }
10 |
11 | public int TemperatureF => 32 + (int)(TemperatureC / 0.5556);
12 |
13 | public string Summary { get; set; }
14 | }
15 | }
--------------------------------------------------------------------------------
/test/LiveBlazorWorkbench/LiveBlazorWorkbench.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | net5.0
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/test/LiveBlazorWorkbench/Pages/Counter.razor:
--------------------------------------------------------------------------------
1 | @page "/counter"
2 |
3 | Counter
4 |
5 | Current count: @currentCount
6 |
7 |
8 |
9 | @code {
10 | private int currentCount = 0;
11 |
12 | private void IncrementCount()
13 | {
14 | currentCount++;
15 | }
16 | }
--------------------------------------------------------------------------------
/test/LiveBlazorWorkbench/Pages/Index.razor:
--------------------------------------------------------------------------------
1 | @page "/"
2 |
3 | Hello!
4 |
5 | Welcome to your new app.11
6 |
7 |
--------------------------------------------------------------------------------
/test/LiveBlazorWorkbench/Shared/MainLayout.razor:
--------------------------------------------------------------------------------
1 | @inherits LayoutComponentBase
2 |
3 |
4 |
7 |
8 |
9 |
12 |
13 |
14 | @Body
15 |
16 |
17 |
--------------------------------------------------------------------------------
/test/LiveBlazorWorkbench/Shared/SurveyPrompt.razor:
--------------------------------------------------------------------------------
1 |
2 |
3 |
@Title
4 |
5 |
6 | Please take our
7 | brief survey
8 |
9 | and tell us what you think.
10 |
11 |
12 | @code {
13 | // Demonstrates how a parent component can supply parameters
14 | [Parameter]
15 | public string Title {
16 | get;
17 | set;
18 | }
19 |
20 | }
--------------------------------------------------------------------------------
/test/LiveBlazorWorkbench/_Imports.razor:
--------------------------------------------------------------------------------
1 | @using System.Net.Http
2 | @using Microsoft.AspNetCore.Authorization
3 | @using Microsoft.AspNetCore.Components.Authorization
4 | @using Microsoft.AspNetCore.Components.Forms
5 | @using Microsoft.AspNetCore.Components.Routing
6 | @using Microsoft.AspNetCore.Components.Web
7 | @using Microsoft.AspNetCore.Components.Web.Virtualization
8 | @using Microsoft.JSInterop
9 | @using LiveBlazorWorkbench
10 | @using LiveBlazorWorkbench.Shared
--------------------------------------------------------------------------------
/test/LiveBlazorWorkbench/appsettings.Development.json:
--------------------------------------------------------------------------------
1 | {
2 | "DetailedErrors": true,
3 | "Logging": {
4 | "LogLevel": {
5 | "Default": "Information",
6 | "Microsoft": "Warning",
7 | "Microsoft.Hosting.Lifetime": "Information"
8 | }
9 | }
10 | }
11 |
--------------------------------------------------------------------------------
/test/LiveBlazorWorkbench/appsettings.json:
--------------------------------------------------------------------------------
1 | {
2 | "Logging": {
3 | "LogLevel": {
4 | "Default": "Information",
5 | "Microsoft": "Warning",
6 | "Microsoft.Hosting.Lifetime": "Information"
7 | }
8 | },
9 | "AllowedHosts": "*"
10 | }
11 |
--------------------------------------------------------------------------------
/test/LiveBlazorWorkbench/wwwroot/css/open-iconic/font/fonts/open-iconic.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ionoy/LiveSharp/754823359f8af8bbee98d5a349b7068e79c84102/test/LiveBlazorWorkbench/wwwroot/css/open-iconic/font/fonts/open-iconic.eot
--------------------------------------------------------------------------------
/test/LiveBlazorWorkbench/wwwroot/css/open-iconic/font/fonts/open-iconic.otf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ionoy/LiveSharp/754823359f8af8bbee98d5a349b7068e79c84102/test/LiveBlazorWorkbench/wwwroot/css/open-iconic/font/fonts/open-iconic.otf
--------------------------------------------------------------------------------
/test/LiveBlazorWorkbench/wwwroot/css/open-iconic/font/fonts/open-iconic.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ionoy/LiveSharp/754823359f8af8bbee98d5a349b7068e79c84102/test/LiveBlazorWorkbench/wwwroot/css/open-iconic/font/fonts/open-iconic.ttf
--------------------------------------------------------------------------------
/test/LiveBlazorWorkbench/wwwroot/css/open-iconic/font/fonts/open-iconic.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ionoy/LiveSharp/754823359f8af8bbee98d5a349b7068e79c84102/test/LiveBlazorWorkbench/wwwroot/css/open-iconic/font/fonts/open-iconic.woff
--------------------------------------------------------------------------------
/test/LiveBlazorWorkbench/wwwroot/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ionoy/LiveSharp/754823359f8af8bbee98d5a349b7068e79c84102/test/LiveBlazorWorkbench/wwwroot/favicon.ico
--------------------------------------------------------------------------------
/test/LiveSharp.BlazorTest.App/App.razor:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | Sorry, there's nothing at this address.
8 |
9 |
10 |
--------------------------------------------------------------------------------
/test/LiveSharp.BlazorTest.App/Data/WeatherForecast.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | namespace LiveSharp.BlazorTest.App.Data
4 | {
5 | public class WeatherForecast
6 | {
7 | public DateTime Date { get; set; }
8 |
9 | public int TemperatureC { get; set; }
10 |
11 | public int TemperatureF => 32 + (int)(TemperatureC / 0.5556);
12 |
13 | public string Summary { get; set; }
14 | }
15 | }
--------------------------------------------------------------------------------
/test/LiveSharp.BlazorTest.App/Data/WeatherForecast.cs.original:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | namespace LiveSharp.BlazorTest.App.Data
4 | {
5 | public class WeatherForecast
6 | {
7 | public DateTime Date { get; set; }
8 |
9 | public int TemperatureC { get; set; }
10 |
11 | public int TemperatureF => 32 + (int)(TemperatureC / 0.5556);
12 |
13 | public string Summary { get; set; }
14 | }
15 | }
--------------------------------------------------------------------------------
/test/LiveSharp.BlazorTest.App/Data/WeatherForecast.cs.update:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | namespace LiveSharp.BlazorTest.App.Data
4 | {
5 | public class WeatherForecast
6 | {
7 | public DateTime Date { get; set; }
8 |
9 | public int TemperatureC { get; set; }
10 |
11 | public int TemperatureF => 320 + (int)(TemperatureC / 0.5556);
12 |
13 | public string Summary { get; set; }
14 | }
15 | }
--------------------------------------------------------------------------------
/test/LiveSharp.BlazorTest.App/LiveSharp.BlazorTest.App.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | net5.0
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/test/LiveSharp.BlazorTest.App/Pages/Counter.razor:
--------------------------------------------------------------------------------
1 | @page "/counter"
2 |
3 | Counter
4 |
5 | Current count: @currentCount
6 |
7 |
8 |
9 | @code {
10 | private int currentCount = 0;
11 |
12 | private void IncrementCount()
13 | {
14 | currentCount++;
15 | }
16 |
17 | }
--------------------------------------------------------------------------------
/test/LiveSharp.BlazorTest.App/Pages/Index.razor:
--------------------------------------------------------------------------------
1 | @page "/"
2 |
3 | Hello, world!
--------------------------------------------------------------------------------
/test/LiveSharp.BlazorTest.App/Pages/Index.razor.original:
--------------------------------------------------------------------------------
1 | @page "/"
2 |
3 | Hello, world!
--------------------------------------------------------------------------------
/test/LiveSharp.BlazorTest.App/Pages/Index.razor.update:
--------------------------------------------------------------------------------
1 | @page "/"
2 |
3 | Hello, world from LiveSharp!
--------------------------------------------------------------------------------
/test/LiveSharp.BlazorTest.App/Shared/MainLayout.razor:
--------------------------------------------------------------------------------
1 | @inherits LayoutComponentBase
2 |
3 |
4 |
7 |
8 |
9 |
12 |
13 |
14 | @Body
15 |
16 |
17 |
--------------------------------------------------------------------------------
/test/LiveSharp.BlazorTest.App/Shared/SurveyPrompt.razor:
--------------------------------------------------------------------------------
1 |
2 |
3 |
@Title
4 |
5 |
6 | Please take our
7 | brief survey
8 |
9 | and tell us what you think.
10 |
11 |
12 | @code {
13 | // Demonstrates how a parent component can supply parameters
14 | [Parameter]
15 | public string Title { get; set; }
16 |
17 | }
--------------------------------------------------------------------------------
/test/LiveSharp.BlazorTest.App/_Imports.razor:
--------------------------------------------------------------------------------
1 | @using System.Net.Http
2 | @using Microsoft.AspNetCore.Authorization
3 | @using Microsoft.AspNetCore.Components.Authorization
4 | @using Microsoft.AspNetCore.Components.Forms
5 | @using Microsoft.AspNetCore.Components.Routing
6 | @using Microsoft.AspNetCore.Components.Web
7 | @using Microsoft.AspNetCore.Components.Web.Virtualization
8 | @using Microsoft.JSInterop
9 | @using LiveSharp.BlazorTest.App
10 | @using LiveSharp.BlazorTest.App.Shared
--------------------------------------------------------------------------------
/test/LiveSharp.BlazorTest.App/appsettings.Development.json:
--------------------------------------------------------------------------------
1 | {
2 | "DetailedErrors": true,
3 | "Logging": {
4 | "LogLevel": {
5 | "Default": "Information",
6 | "Microsoft": "Warning",
7 | "Microsoft.Hosting.Lifetime": "Information"
8 | }
9 | }
10 | }
11 |
--------------------------------------------------------------------------------
/test/LiveSharp.BlazorTest.App/appsettings.json:
--------------------------------------------------------------------------------
1 | {
2 | "Logging": {
3 | "LogLevel": {
4 | "Default": "Information",
5 | "Microsoft": "Warning",
6 | "Microsoft.Hosting.Lifetime": "Information"
7 | }
8 | },
9 | "AllowedHosts": "*"
10 | }
11 |
--------------------------------------------------------------------------------
/test/LiveSharp.BlazorTest.App/wwwroot/css/open-iconic/font/fonts/open-iconic.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ionoy/LiveSharp/754823359f8af8bbee98d5a349b7068e79c84102/test/LiveSharp.BlazorTest.App/wwwroot/css/open-iconic/font/fonts/open-iconic.eot
--------------------------------------------------------------------------------
/test/LiveSharp.BlazorTest.App/wwwroot/css/open-iconic/font/fonts/open-iconic.otf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ionoy/LiveSharp/754823359f8af8bbee98d5a349b7068e79c84102/test/LiveSharp.BlazorTest.App/wwwroot/css/open-iconic/font/fonts/open-iconic.otf
--------------------------------------------------------------------------------
/test/LiveSharp.BlazorTest.App/wwwroot/css/open-iconic/font/fonts/open-iconic.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ionoy/LiveSharp/754823359f8af8bbee98d5a349b7068e79c84102/test/LiveSharp.BlazorTest.App/wwwroot/css/open-iconic/font/fonts/open-iconic.ttf
--------------------------------------------------------------------------------
/test/LiveSharp.BlazorTest.App/wwwroot/css/open-iconic/font/fonts/open-iconic.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ionoy/LiveSharp/754823359f8af8bbee98d5a349b7068e79c84102/test/LiveSharp.BlazorTest.App/wwwroot/css/open-iconic/font/fonts/open-iconic.woff
--------------------------------------------------------------------------------
/test/LiveSharp.BlazorTest.App/wwwroot/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ionoy/LiveSharp/754823359f8af8bbee98d5a349b7068e79c84102/test/LiveSharp.BlazorTest.App/wwwroot/favicon.ico
--------------------------------------------------------------------------------
/test/LiveSharp.RuntimeTests/Infrastructure/ReflectionExtensions.cs:
--------------------------------------------------------------------------------
1 | using System.Linq;
2 | using System.Reflection;
3 |
4 | namespace LiveSharp.RuntimeTests.Infrastructure
5 | {
6 | public static class ReflectionExtensions
7 | {
8 | public static string GetMethodIdentifier(this MethodInfo methodInfo)
9 | {
10 | var parameters = methodInfo.GetParameters();
11 | var parameterString = string.Join(" ", parameters.Select(p => p.ParameterType.FullName));
12 | return
13 | $"{methodInfo.DeclaringType.FullName} {methodInfo.Name} {parameterString}";
14 | }
15 | }
16 | }
--------------------------------------------------------------------------------
/test/LiveSharp.RuntimeTests/Log.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Diagnostics;
3 |
4 | namespace LiveSharp.RuntimeTests
5 | {
6 | public class Log
7 | {
8 | public static void WriteLine(string line)
9 | {
10 | Console.WriteLine(line);
11 | Debug.WriteLine(line);
12 | }
13 | public static void WriteLine(object line)
14 | {
15 | Console.WriteLine(line);
16 | Debug.WriteLine(line);
17 | }
18 | }
19 | }
--------------------------------------------------------------------------------
/test/LiveSharp.RuntimeTests/MyControlViewModel.cs:
--------------------------------------------------------------------------------
1 | namespace LiveSharp.RuntimeTests
2 | {
3 | internal class MyControlViewModel
4 | {
5 | public MyControlViewModel(int a, string b)
6 | {
7 | }
8 |
9 | public MyControlViewModel(int a)
10 | {
11 | }
12 |
13 |
14 | public object RegistrationPrompt { get; internal set; }
15 | public object RegistrationCodeValidationMessage { get; internal set; }
16 | public object RegistrationCode { get; internal set; }
17 | }
18 | }
--------------------------------------------------------------------------------
/test/LiveSharp.RuntimeTests/Sequences/BubblesGame/MainPage.xaml.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Linq;
4 | using System.Text;
5 | using System.Threading.Tasks;
6 | using Xamarin.Forms;
7 |
8 | namespace XamarinWorkbench
9 | {
10 | public partial class MainPage : ContentPage
11 | {
12 | public MainPage()
13 | {
14 | Build();
15 | }
16 |
17 | public void Build()
18 | {
19 | Content = new Label {
20 | Text = "Hello, World!"
21 | };
22 | }
23 |
24 | }
25 | }
--------------------------------------------------------------------------------
/test/LiveSharp.RuntimeTests/Sequences/ChangeReturnValue/ChangeReturnValue.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | namespace LiveSharp.RuntimeTests.Sequences.ChangeReturnValue
4 | {
5 | public class ChangeReturnValue : IRunnableSequence
6 | {
7 | public void Run()
8 | {
9 | Console.WriteLine(ReturnValue());
10 | }
11 | private int ReturnValue() => 5;
12 | }
13 | }
--------------------------------------------------------------------------------
/test/LiveSharp.RuntimeTests/Sequences/ChangeReturnValue/ChangeReturnValue.cs.1:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 |
4 | namespace LiveSharp.RuntimeTests.Sequences.ChangeReturnValue
5 | {
6 | public class ChangeReturnValue : IRunnableSequence
7 | {
8 | public void Run()
9 | {
10 | Console.WriteLine(ReturnValue());
11 | }
12 | private Dictionary ReturnValue() => new Dictionary();
13 | }
14 | }
--------------------------------------------------------------------------------
/test/LiveSharp.RuntimeTests/Sequences/DynamicIndex/DynamicIndex.cs:
--------------------------------------------------------------------------------
1 | namespace LiveSharp.RuntimeTests.Sequences.DynamicIndex
2 | {
3 | public class DynamicIndex : TestsBase, IRunnableSequence
4 | {
5 | public void Run()
6 | {
7 | }
8 | }
9 | }
--------------------------------------------------------------------------------
/test/LiveSharp.RuntimeTests/Sequences/DynamicIndex/DynamicIndex.cs.1:
--------------------------------------------------------------------------------
1 | namespace LiveSharp.RuntimeTests.Sequences.DynamicIndex
2 | {
3 | public class DynamicIndex : TestsBase, IRunnableSequence
4 | {
5 | public void Run()
6 | {
7 | var a = ThisBreaksLiveSharp();
8 |
9 | AssertEqual(a, 1);
10 | }
11 |
12 | private static int ThisBreaksLiveSharp() {
13 | var a = new []{1, 2};
14 | dynamic d = a;
15 | return d[0];
16 | }
17 | }
18 | }
--------------------------------------------------------------------------------
/test/LiveSharp.RuntimeTests/Sequences/IRunnableSequence.cs:
--------------------------------------------------------------------------------
1 | namespace LiveSharp.RuntimeTests.Sequences
2 | {
3 | public interface IRunnableSequence
4 | {
5 | void Run();
6 | }
7 | }
--------------------------------------------------------------------------------
/test/LiveSharp.RuntimeTests/TestRunner.MockDeviceInfo.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using Xamarin.Forms;
3 | using Xamarin.Forms.Internals;
4 |
5 | namespace LiveSharp.RuntimeTests
6 | {
7 | public partial class TestRunner
8 | {
9 | internal class MockDeviceInfo : DeviceInfo
10 | {
11 | public override Size PixelScreenSize => throw new NotImplementedException();
12 |
13 | public override Size ScaledScreenSize => throw new NotImplementedException();
14 |
15 | public override double ScalingFactor => throw new NotImplementedException();
16 | }
17 | }
18 | }
--------------------------------------------------------------------------------
/test/LiveSharp.RuntimeTests/Tests/DelegateTests.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | namespace LiveSharp.RuntimeTests
4 | {
5 | public class DelegateTests : TestsBase
6 | {
7 | delegate double FuncDouble ();
8 |
9 | public void Test0()
10 | {
11 | var func = new Func(() => 1.0);
12 | }
13 |
14 | public void Test1()
15 | {
16 | var func = new FuncDouble(() => 1.0);
17 | }
18 |
19 | public void Test2()
20 | {
21 | var func = new EventHandler((sender, args) => { });
22 | }
23 | }
24 | }
--------------------------------------------------------------------------------
/test/LiveSharp.RuntimeTests/Tests/DynamicTests.cs:
--------------------------------------------------------------------------------
1 | namespace LiveSharp.RuntimeTests.Tests
2 | {
3 | public class DynamicTests : TestsBase
4 | {
5 | public void Test0()
6 | {
7 | var a = new []{1, 2};
8 | dynamic d = a;
9 | int b = d[0];
10 | }
11 | }
12 | }
--------------------------------------------------------------------------------
/test/LiveSharp.RuntimeTests/Tests/InheritanceTests.cs:
--------------------------------------------------------------------------------
1 | namespace LiveSharp.RuntimeTests.Tests
2 | {
3 | public class InheritanceTests : TestsBase
4 | {
5 | public override bool TestOverride()
6 | {
7 | Assert(base.TestOverride());
8 | return true;
9 | }
10 | }
11 | }
--------------------------------------------------------------------------------
/test/LiveSharp.RuntimeTests/Tests/LockTests.cs:
--------------------------------------------------------------------------------
1 | namespace LiveSharp.RuntimeTests
2 | {
3 | public class LockTests : TestsBase
4 | {
5 | public void Test0()
6 | {
7 | var b = false;
8 |
9 | lock (_lockObject)
10 | b = true;
11 |
12 | AssertEqual(b, true);
13 | }
14 |
15 | #region Helpers
16 |
17 | readonly object _lockObject = new object();
18 |
19 | #endregion
20 | }
21 | }
--------------------------------------------------------------------------------
/test/LiveSharp.RuntimeTests/Tests/PropertyTests.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Text;
4 |
5 | namespace LiveSharp.RuntimeTests.Tests
6 | {
7 | class PropertyTests : TestsBase
8 | {
9 | public List List => new List();
10 | public List List2 { get { return new List(); } }
11 | }
12 | }
13 |
--------------------------------------------------------------------------------
/test/LiveSharp.RuntimeTests/Tests/ReturnTests.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Linq;
4 | using System.Text;
5 | using System.Threading.Tasks;
6 |
7 | namespace LiveSharp.RuntimeTests
8 | {
9 | public class ReturnTests : TestsBase
10 | {
11 | public void Test0()
12 | {
13 | Assert(true);
14 |
15 | if (true)
16 | return;
17 |
18 | Assert(false);
19 | }
20 | }
21 | }
22 |
--------------------------------------------------------------------------------
/test/LiveSharp.RuntimeTests/Tests/StringTests.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using LiveSharp.Ide.Infrastructure;
3 |
4 | namespace LiveSharp.RuntimeTests.Tests
5 | {
6 | public class StringTests : TestsBase
7 | {
8 | public void Test10 ()
9 | {
10 | var s = $"abc{1}";
11 | AssertEqual(s, "abc1");
12 | }
13 |
14 | public void Test20 ()
15 | {
16 | var s = $@"abc{1}";
17 | AssertEqual(s, "abc1");
18 | }
19 |
20 | public void Test30 ()
21 | {
22 | var s = new string(" ");
23 | AssertEqual(s.Length, 1);
24 | }
25 | }
26 | }
--------------------------------------------------------------------------------
/test/LiveSharp.RuntimeTests/Tests/StructTests.cs:
--------------------------------------------------------------------------------
1 | namespace LiveSharp.RuntimeTests.Tests
2 | {
3 | public class StructTests : TestsBase
4 | {
5 | public void Test0()
6 | {
7 | var arrayTest = new[] {new MyTest()};
8 | arrayTest[0].a = 3;
9 |
10 | AssertEqual(arrayTest[0].a, 3);
11 | }
12 |
13 | struct MyTest {
14 | public int a;
15 | };
16 | }
17 | }
--------------------------------------------------------------------------------
/test/LiveSharp.SequenceRecorder/LiveSharp.SequenceRecorder.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Exe
5 | netcoreapp3.1
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
--------------------------------------------------------------------------------
/test/LiveSharp.ServerTest/LiveSharp.ServerTest.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | net5.0
5 | Exe
6 |
7 | false
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/test/LiveSharp.UnitTests/LiveSharp.UnitTests.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | net5.0
5 |
6 | false
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
--------------------------------------------------------------------------------
/test/LiveSharp.WorkspaceTester/LiveSharp.WorkspaceTester.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Exe
5 | netcoreapp2.2
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
--------------------------------------------------------------------------------
/test/XamarinFormsTest/XamarinFormsTest.Android/Properties/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/test/XamarinFormsTest/XamarinFormsTest.Android/Resources/drawable/xamarin_logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ionoy/LiveSharp/754823359f8af8bbee98d5a349b7068e79c84102/test/XamarinFormsTest/XamarinFormsTest.Android/Resources/drawable/xamarin_logo.png
--------------------------------------------------------------------------------
/test/XamarinFormsTest/XamarinFormsTest.Android/Resources/layout/Tabbar.axml:
--------------------------------------------------------------------------------
1 |
2 |
12 |
--------------------------------------------------------------------------------
/test/XamarinFormsTest/XamarinFormsTest.Android/Resources/layout/Toolbar.axml:
--------------------------------------------------------------------------------
1 |
9 |
10 |
--------------------------------------------------------------------------------
/test/XamarinFormsTest/XamarinFormsTest.Android/Resources/mipmap-anydpi-v26/icon.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/test/XamarinFormsTest/XamarinFormsTest.Android/Resources/mipmap-anydpi-v26/icon_round.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/test/XamarinFormsTest/XamarinFormsTest.Android/Resources/mipmap-hdpi/icon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ionoy/LiveSharp/754823359f8af8bbee98d5a349b7068e79c84102/test/XamarinFormsTest/XamarinFormsTest.Android/Resources/mipmap-hdpi/icon.png
--------------------------------------------------------------------------------
/test/XamarinFormsTest/XamarinFormsTest.Android/Resources/mipmap-hdpi/launcher_foreground.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ionoy/LiveSharp/754823359f8af8bbee98d5a349b7068e79c84102/test/XamarinFormsTest/XamarinFormsTest.Android/Resources/mipmap-hdpi/launcher_foreground.png
--------------------------------------------------------------------------------
/test/XamarinFormsTest/XamarinFormsTest.Android/Resources/mipmap-mdpi/icon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ionoy/LiveSharp/754823359f8af8bbee98d5a349b7068e79c84102/test/XamarinFormsTest/XamarinFormsTest.Android/Resources/mipmap-mdpi/icon.png
--------------------------------------------------------------------------------
/test/XamarinFormsTest/XamarinFormsTest.Android/Resources/mipmap-mdpi/launcher_foreground.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ionoy/LiveSharp/754823359f8af8bbee98d5a349b7068e79c84102/test/XamarinFormsTest/XamarinFormsTest.Android/Resources/mipmap-mdpi/launcher_foreground.png
--------------------------------------------------------------------------------
/test/XamarinFormsTest/XamarinFormsTest.Android/Resources/mipmap-xhdpi/icon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ionoy/LiveSharp/754823359f8af8bbee98d5a349b7068e79c84102/test/XamarinFormsTest/XamarinFormsTest.Android/Resources/mipmap-xhdpi/icon.png
--------------------------------------------------------------------------------
/test/XamarinFormsTest/XamarinFormsTest.Android/Resources/mipmap-xhdpi/launcher_foreground.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ionoy/LiveSharp/754823359f8af8bbee98d5a349b7068e79c84102/test/XamarinFormsTest/XamarinFormsTest.Android/Resources/mipmap-xhdpi/launcher_foreground.png
--------------------------------------------------------------------------------
/test/XamarinFormsTest/XamarinFormsTest.Android/Resources/mipmap-xxhdpi/icon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ionoy/LiveSharp/754823359f8af8bbee98d5a349b7068e79c84102/test/XamarinFormsTest/XamarinFormsTest.Android/Resources/mipmap-xxhdpi/icon.png
--------------------------------------------------------------------------------
/test/XamarinFormsTest/XamarinFormsTest.Android/Resources/mipmap-xxhdpi/launcher_foreground.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ionoy/LiveSharp/754823359f8af8bbee98d5a349b7068e79c84102/test/XamarinFormsTest/XamarinFormsTest.Android/Resources/mipmap-xxhdpi/launcher_foreground.png
--------------------------------------------------------------------------------
/test/XamarinFormsTest/XamarinFormsTest.Android/Resources/mipmap-xxxhdpi/icon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ionoy/LiveSharp/754823359f8af8bbee98d5a349b7068e79c84102/test/XamarinFormsTest/XamarinFormsTest.Android/Resources/mipmap-xxxhdpi/icon.png
--------------------------------------------------------------------------------
/test/XamarinFormsTest/XamarinFormsTest.Android/Resources/mipmap-xxxhdpi/launcher_foreground.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ionoy/LiveSharp/754823359f8af8bbee98d5a349b7068e79c84102/test/XamarinFormsTest/XamarinFormsTest.Android/Resources/mipmap-xxxhdpi/launcher_foreground.png
--------------------------------------------------------------------------------
/test/XamarinFormsTest/XamarinFormsTest.Android/Resources/values/colors.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | #FFFFFF
4 | #3F51B5
5 | #303F9F
6 | #FF4081
7 |
8 |
--------------------------------------------------------------------------------
/test/XamarinFormsTest/XamarinFormsTest/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using Xamarin.Forms.Xaml;
2 |
3 | [assembly: XamlCompilation(XamlCompilationOptions.Compile)]
--------------------------------------------------------------------------------
/test/XamarinFormsTest/XamarinFormsTest/FodyWeavers.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/test/XamarinFormsTest/XamarinFormsTest/Models/HomeMenuItem.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Text;
4 |
5 | namespace XamarinFormsTest.Models
6 | {
7 | public enum MenuItemType
8 | {
9 | Browse,
10 | About
11 | }
12 | public class HomeMenuItem
13 | {
14 | public MenuItemType Id { get; set; }
15 |
16 | public string Title { get; set; }
17 | }
18 | }
19 |
--------------------------------------------------------------------------------
/test/XamarinFormsTest/XamarinFormsTest/Models/Item.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | namespace XamarinFormsTest.Models
4 | {
5 | public class Item
6 | {
7 | public string Id { get; set; }
8 | public string Text { get; set; }
9 | public string Description { get; set; }
10 |
11 | public override string ToString()
12 | {
13 | return Text + "\n" + Description;
14 | }
15 | }
16 | }
--------------------------------------------------------------------------------
/test/XamarinFormsTest/XamarinFormsTest/Services/IDataStore.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Threading.Tasks;
4 |
5 | namespace XamarinFormsTest.Services
6 | {
7 | public interface IDataStore
8 | {
9 | Task AddItemAsync(T item);
10 | Task UpdateItemAsync(T item);
11 | Task DeleteItemAsync(string id);
12 | Task GetItemAsync(string id);
13 | Task> GetItemsAsync(bool forceRefresh = false);
14 | }
15 | }
16 |
--------------------------------------------------------------------------------
/test/XamarinWorkbench/XamarinWorkbench.Android/Properties/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/test/XamarinWorkbench/XamarinWorkbench.Android/Resources/layout/Tabbar.axml:
--------------------------------------------------------------------------------
1 |
2 |
12 |
--------------------------------------------------------------------------------
/test/XamarinWorkbench/XamarinWorkbench.Android/Resources/layout/Toolbar.axml:
--------------------------------------------------------------------------------
1 |
9 |
10 |
--------------------------------------------------------------------------------
/test/XamarinWorkbench/XamarinWorkbench.Android/Resources/values/colors.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | #FFFFFF
4 | #3F51B5
5 | #303F9F
6 | #FF4081
7 |
8 |
--------------------------------------------------------------------------------
/test/XamarinWorkbench/XamarinWorkbench/App.xaml:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/test/XamarinWorkbench/XamarinWorkbench/FodyWeavers.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/test/XamarinWorkbench/XamarinWorkbench/MainPage.xaml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/test/XamarinWorkbench/XamarinWorkbench/Model.cs:
--------------------------------------------------------------------------------
1 | namespace XamarinWorkbench
2 | {
3 | public class Model
4 | {
5 | private readonly string _name;
6 | public string Name => ", " + _name;
7 |
8 | public Model(string name)
9 | {
10 | _name = name;
11 | }
12 | }
13 | }
--------------------------------------------------------------------------------