This commit is contained in:
Jerome Laban 2019-06-14 10:52:24 -04:00
Коммит 9581caba83
29 изменённых файлов: 1787 добавлений и 0 удалений

223
.editorconfig Normal file
Просмотреть файл

@ -0,0 +1,223 @@
root = true
[*]
end_of_line = crlf
tab_width = 4
trim_trailing_whitespace = true
insert_final_newline = true
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_indent_block_contents
csharp_indent_block_contents = true
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_indent_braces
csharp_indent_braces = false
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_indent_case_contents
csharp_indent_case_contents = true
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_indent_labels
csharp_indent_labels = one_less_than_current
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_indent_switch_labels
csharp_indent_switch_labels = true
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_new_line_before_catch
csharp_new_line_before_catch = true
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_new_line_before_else
csharp_new_line_before_else = true
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_new_line_before_finally
csharp_new_line_before_finally = true
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_new_line_before_members_in_anonymous_types
csharp_new_line_before_members_in_anonymous_types = true
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_new_line_before_members_in_object_initializers
csharp_new_line_before_members_in_object_initializers = true
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_new_line_before_open_brace
csharp_new_line_before_open_brace = all
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_new_line_between_query_expression_clauses
csharp_new_line_between_query_expression_clauses = true
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_prefer_braces
csharp_prefer_braces = true:suggestion
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_prefer_simple_default_expression
csharp_prefer_simple_default_expression = true:suggestion
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_preserve_single_line_blocks
csharp_preserve_single_line_blocks = true
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_preserve_single_line_statements
csharp_preserve_single_line_statements = false
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_space_after_cast
csharp_space_after_cast = false
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_space_after_colon_in_inheritance_clause
csharp_space_after_colon_in_inheritance_clause = true
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_space_after_comma
csharp_space_after_comma = true
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_space_after_dot
csharp_space_after_dot = false
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_space_after_keywords_in_control_flow_statements
csharp_space_after_keywords_in_control_flow_statements = false
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_space_after_semicolon_in_for_statement
csharp_space_after_semicolon_in_for_statement = true
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_space_around_binary_operators
csharp_space_around_binary_operators = before_and_after
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_space_around_declaration_statements
csharp_space_around_declaration_statements = do_not_ignore
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_space_before_colon_in_inheritance_clause
csharp_space_before_colon_in_inheritance_clause = true
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_space_before_comma
csharp_space_before_comma = false
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_space_before_dot
csharp_space_before_dot = false
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_space_before_open_square_brackets
csharp_space_before_open_square_brackets = false
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_space_before_semicolon_in_for_statement
csharp_space_before_semicolon_in_for_statement = false
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_space_between_empty_square_brackets
csharp_space_between_empty_square_brackets = false
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_space_between_method_call_empty_parameter_list_parentheses
csharp_space_between_method_call_empty_parameter_list_parentheses = false
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_space_between_method_call_name_and_opening_parenthesis
csharp_space_between_method_call_name_and_opening_parenthesis = false
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_space_between_method_call_parameter_list_parentheses
csharp_space_between_method_call_parameter_list_parentheses = false
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_space_between_method_declaration_empty_parameter_list_parentheses
csharp_space_between_method_declaration_empty_parameter_list_parentheses = false
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_space_between_method_declaration_name_and_open_parenthesis
csharp_space_between_method_declaration_name_and_open_parenthesis = false
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_space_between_method_declaration_parameter_list_parentheses
csharp_space_between_method_declaration_parameter_list_parentheses = false
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_space_between_parentheses
csharp_space_between_parentheses = none
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_space_between_square_brackets
csharp_space_between_square_brackets = false
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_style_conditional_delegate_call
csharp_style_conditional_delegate_call = true:suggestion
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_style_expression_bodied_accessors
csharp_style_expression_bodied_accessors = true:suggestion
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_style_expression_bodied_constructors
csharp_style_expression_bodied_constructors = false:suggestion
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_style_expression_bodied_indexers
csharp_style_expression_bodied_indexers = true:suggestion
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_style_expression_bodied_methods
csharp_style_expression_bodied_methods = true:suggestion
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_style_expression_bodied_operators
csharp_style_expression_bodied_operators = true:suggestion
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_style_expression_bodied_properties
csharp_style_expression_bodied_properties = true:suggestion
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_style_inlined_variable_declaration
csharp_style_inlined_variable_declaration = true:suggestion
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_style_pattern_matching_over_as_with_null_check
csharp_style_pattern_matching_over_as_with_null_check = true:suggestion
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_style_pattern_matching_over_is_with_cast_check
csharp_style_pattern_matching_over_is_with_cast_check = true:suggestion
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_style_throw_expression
csharp_style_throw_expression = true:suggestion
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_style_var_elsewhere
csharp_style_var_elsewhere = true:suggestion
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_style_var_for_built_in_types
csharp_style_var_for_built_in_types = true:suggestion
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#csharp_style_var_when_type_is_apparent
csharp_style_var_when_type_is_apparent = true:suggestion
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#dotnet_sort_system_directives_first
dotnet_sort_system_directives_first = true
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#dotnet_style_coalesce_expression
dotnet_style_coalesce_expression = true:suggestion
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#dotnet_style_collection_initializer
dotnet_style_collection_initializer = true:suggestion
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#dotnet_style_explicit_tuple_names
dotnet_style_explicit_tuple_names = true:suggestion
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#dotnet_style_null_propagation
dotnet_style_null_propagation = true:suggestion
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#dotnet_style_object_initializer
dotnet_style_object_initializer = true:suggestion
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#dotnet_style_predefined_type_for_locals_parameters_members
dotnet_style_predefined_type_for_locals_parameters_members = true:suggestion
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#dotnet_style_predefined_type_for_member_access
dotnet_style_predefined_type_for_member_access = true:suggestion
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#dotnet_style_qualification_for_event
dotnet_style_qualification_for_event = false:suggestion
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#dotnet_style_qualification_for_field
dotnet_style_qualification_for_field = false:suggestion
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#dotnet_style_qualification_for_method
dotnet_style_qualification_for_method = false:suggestion
# http://kent-boogaart.com/blog/editorconfig-reference-for-c-developers#dotnet_style_qualification_for_property
dotnet_style_qualification_for_property = false:suggestion
[{*.xaml, *.xml, *.targets, *.props}]
indent_style = tab
[{*.cs, *.tt}]
indent_style = tab
[{*.ts, *.json}]
indent_style = tab
[*.csproj]
indent_style = tab
tab_width = 2
indent_size = 2
[*.js]
indent_style = space
[*.yml]
indent_style = space
[*.md]
indent_style = space

39
.github/ISSUE_TEMPLATE.md поставляемый Normal file
Просмотреть файл

@ -0,0 +1,39 @@
<!--
PLEASE HELP US PROCESS GITHUB ISSUES FASTER BY PROVIDING THE FOLLOWING INFORMATION.
ISSUES MISSING IMPORTANT INFORMATION MAY BE CLOSED WITHOUT INVESTIGATION.
-->
## I'm submitting a...
<!-- Please uncomment one or more that apply to this issue -->
<!-- - Regression (a behavior that used to work and stopped working in a new release) -->
<!-- - Bug report (I searched for similar issues and did not find one) -->
<!-- - Feature request -->
<!-- - Sample app request -->
<!-- - Documentation issue or request -->
<!-- - Question of Support request => Please do not submit support request here, instead see https://github.com/nventive/Uno.Core/blob/master/Readme.md#have-questions-feature-requests-issues -->
## Current behavior
<!-- Describe how the issue manifests. -->
## Expected behavior
<!-- Describe what the desired behavior would be. -->
## Minimal reproduction of the problem with instructions
<!--
For bug reports please provide a *MINIMAL REPRO PROJECT* and the *STEPS TO REPRODUCE*
-->
## Environment
<!-- For bug reports Check one or more of the following options with "x" -->
```
Package Version(s):
Visual Studio
- [ ] 2017 (version: )
- [ ] 2017 Preview (version: )
- [ ] for Mac (version: )
```

41
.github/PULL_REQUEST_TEMPLATE.md поставляемый Normal file
Просмотреть файл

@ -0,0 +1,41 @@
GitHub Issue (If applicable): #
<!-- Link to relevant GitHub issue if applicable. All PRs should be associated with an issue (GitHub issue or internal) -->
## PR Type
What kind of change does this PR introduce?
<!-- Please uncomment one ore more that apply to this PR -->
<!-- - Bugfix -->
<!-- - Feature -->
<!-- - Code style update (formatting) -->
<!-- - Refactoring (no functional changes, no api changes) -->
<!-- - Build or CI related changes -->
<!-- - Documentation content changes -->
<!-- - Other... Please describe: -->
## What is the current behavior?
<!-- Please describe the current behavior that you are modifying, or link to a relevant issue. -->
## What is the new behavior?
<!-- Please describe the new behavior after your modifications. -->
## PR Checklist
Please check if your PR fulfills the following requirements:
- [ ] Tests for the changes have been added (for bug fixes / features) (if applicable)
- [ ] Contains **NO** breaking changes
- [ ] Associated with an issue (GitHub or internal)
<!-- If this PR contains a breaking change, please describe the impact and migration path for existing applications below.
Please note that breaking changes are likely to be rejected -->
## Other information
<!-- Please provide any additional information if necessary -->
Internal Issue (If applicable):
<!-- Link to relevant internal issue if applicable. All PRs should be associated with an issue (GitHub issue or internal) -->

235
.gitignore поставляемый Normal file
Просмотреть файл

@ -0,0 +1,235 @@
## Ignore Visual Studio temporary files, build results, and
## files generated by popular Visual Studio add-ons.
# Remove everything beginning with a dot
.*/
!.github/
# User-specific files
*.suo
*.user
*.userosscache
*.sln.docstates
# User-specific files (MonoDevelop/Xamarin Studio)
*.userprefs
launchSettings.json
# Build results
[Dd]ebug[-\w]*/
[Dd]ebugPublic/
[Rr]elease[-\w]*/
[Rr]eleases/
[Xx]64/
[Xx]86/
# [Bb]uild/
bld/
[Bb]in/
[Oo]bj/
# Visual Studio 2015 cache/options directory
.vs/
# Uncomment if you have tasks that create the project's static files in wwwroot
#wwwroot/
# MSTest test Results
[Tt]est[Rr]esult*/
[Bb]uild[Ll]og.*
# NUNIT
*.VisualState.xml
TestResult.xml
# Build Results of an ATL Project
[Dd]ebugPS/
[Rr]eleasePS/
dlldata.c
# DNX
project.lock.json
artifacts/
*_i.c
*_p.c
*_i.h
*.ilk
*.meta
*.obj
*.pch
*.pdb
*.mdb
*.pgc
*.pgd
*.rsp
*.sbr
*.tlb
*.tli
*.tlh
*.tmp
*.tmp_proj
*.log
*.vspscc
*.vssscc
.builds
*.pidb
*.svclog
*.binlog
*.scc
# Chutzpah Test files
_Chutzpah*
# Visual C++ cache files
ipch/
*.aps
*.ncb
*.opendb
*.opensdf
*.sdf
*.cachefile
*.VC.db
# Visual Studio profiler
*.psess
*.vsp
*.vspx
*.sap
# TFS 2012 Local Workspace
$tf/
# Guidance Automation Toolkit
*.gpState
# ReSharper is a .NET coding add-in
_ReSharper*/
*.[Rr]e[Ss]harper
*.DotSettings.user
# JustCode is a .NET coding add-in
.JustCode
# DotCover is a Code Coverage Tool
*.dotCover
# MightyMoose
*.mm.*
AutoTest.Net/
# DocProject is a documentation generator add-in
DocProject/buildhelp/
DocProject/Help/*.HxT
DocProject/Help/*.HxC
DocProject/Help/*.hhc
DocProject/Help/*.hhk
DocProject/Help/*.hhp
DocProject/Help/Html2
DocProject/Help/html
# Click-Once directory
publish/
# Publish Web Output
*.[Pp]ublish.xml
*.azurePubxml
# TODO: Un-comment the next line if you do not want to checkin
# your web deploy settings because they may include unencrypted
# passwords
#*.pubxml
*.publishproj
# NuGet Packages
#*.nupkg
# The packages folder can be ignored because of Package Restore
#**/packages/*
# except build/, which is used as an MSBuild target.
#!**/packages/build/
# Uncomment if necessary however generally it will be regenerated when needed
#!**/packages/repositories.config
# NuGet v3's project.json files produces more ignoreable files
*.nuget.props
*.nuget.targets
# Microsoft Azure Build Output
csx/
*.build.csdef
# Microsoft Azure Emulator
ecf/
rcf/
# Microsoft Azure ApplicationInsights config file
ApplicationInsights.config
# Windows Store app package directory
AppPackages/
BundleArtifacts/
# Visual Studio cache files
# files ending in .cache can be ignored
*.[Cc]ache
# but keep track of directories ending in .cache
!*.[Cc]ache/
# Others
ClientBin/
[Ss]tyle[Cc]op.*
~$*
*~
*.dbmdl
*.dbproj.schemaview
*.pfx
*.publishsettings
node_modules/
orleans.codegen.cs
# RIA/Silverlight projects
Generated_Code/
# Backup & report files from converting an old project file
# to a newer Visual Studio version. Backup files are not needed,
# because we have git ;-)
_UpgradeReport_Files/
Backup*/
UpgradeLog*.XML
UpgradeLog*.htm
# SQL Server files
*.mdf
*.ldf
# Business Intelligence projects
*.rdl.data
*.bim.layout
*.bim_*.settings
# Microsoft Fakes
FakesAssemblies/
# GhostDoc plugin setting file
*.GhostDoc.xml
# Node.js Tools for Visual Studio
.ntvs_analysis.dat
# Visual Studio 6 build log
*.plg
# Visual Studio 6 workspace options file
*.opt
# Paket dependency manager
.paket/paket.exe
# FAKE - F# Make
.fake/
# Xamarin Android
Resource.Designer.cs
*.bak
*/nuget_version_override.txt
/src/crosstargeting_override.props
/build/tools/**
!build/tools/packages.config
/build/*.nupkg

115
.vsts-ci.yml Normal file
Просмотреть файл

@ -0,0 +1,115 @@
jobs:
- job: Windows
pool:
name: Hosted
variables:
NUGET_PACKAGES: $(Agent.WorkFolder)\.nuget
steps:
- checkout: self
clean: true
- task: NuGetToolInstaller@0
inputs:
versionSpec: 4.9.1
checkLatest: false
- task: GitVersion@4
# Ignore gitversion for forks, until this is fixed:
# https://developercommunity.visualstudio.com/content/problem/284991/public-vsts-previouw-cant-set-build-number-of-pr-b.html
condition: eq(variables['System.PullRequest.IsFork'], 'False')
inputs:
updateAssemblyInfo: false
- task: DotNetCoreInstaller@0
inputs:
version: '2.2.103'
- task: DotNetCoreCLI@2
displayName: .NET Core Build
inputs:
command: build
arguments: --configuration Release "/p:PackageOutputPath=$(build.artifactstagingdirectory)\nuget" "-p:PackageVersion=$(GITVERSION.FullSemVer)" "/p:InformationalVersion=$(GITVERSION.InformationalVersion)" /detailedsummary
workingDirectory: $(build.sourcesdirectory)\src
- task: DotNetCoreInstaller@0
inputs:
version: '2.1.504'
- task: PowerShell@2
displayName: Authenticode Sign Packages
inputs:
filePath: build/Sign-Package.ps1
env:
SignClientUser: $(SignClientUser)
SignClientSecret: $(SignClientSecret)
SignPackageName: "Uno.PackageDiff"
SignPackageDescription: "Uno.PackageDiff"
ArtifactDirectory: $(build.artifactstagingdirectory)
condition: and(succeeded(), not(eq(variables['build.reason'], 'PullRequest')), not(eq(variables['SignClientSecret'], '')), not(eq(variables['SignClientUser'], '')))
- task: PublishBuildArtifacts@1
condition: always()
inputs:
PathtoPublish: $(build.artifactstagingdirectory)
ArtifactName: unosourcegenerator-drop
ArtifactType: Container
- task: VSTest@2
inputs:
testAssemblyVer2: |
**\*tests.dll
!**\obj\**
vstestLocationMethod: version
vsTestVersion: latest
testSelector: testAssemblies
- job: Linux
workspace:
clean: all
pool:
name: Default
demands:
- agent.os -equals Linux
variables:
NUGET_PACKAGES: $(Agent.WorkFolder)/.nuget
steps:
- checkout: self
clean: true
- task: DotNetCoreInstaller@0
inputs:
version: '2.2.103'
- task: DotNetCoreCLI@2
displayName: .NET Core Build
inputs:
command: build
arguments: --configuration Release /detailedsummary
workingDirectory: $(build.sourcesdirectory)/src
- job: macOS
pool:
vmImage: 'macOS-10.13'
variables:
NUGET_PACKAGES: $(Agent.WorkFolder)/.nuget
SourceLinkEnabled: false
steps:
- task: DotNetCoreInstaller@0
inputs:
version: '2.2.103'
- task: DotNetCoreCLI@2
displayName: .NET Core Build
inputs:
command: build
arguments: --configuration Release /detailedsummary
workingDirectory: $(build.sourcesdirectory)/src

3
CODE_OF_CONDUCT.md Normal file
Просмотреть файл

@ -0,0 +1,3 @@
# Code of Conduct
This project has adopted the code of conduct defined by the Contributor Covenant to clarify expected behavior in our community. For more information, see the [.NET Foundation Code of Conduct](https://dotnetfoundation.org/code-of-conduct).

69
CONTRIBUTING.md Normal file
Просмотреть файл

@ -0,0 +1,69 @@
# How to contribute
There are lots of ways to contribute to the Uno Core and we appreciate the help from the community. You can provide feedback, report bugs, give suggestions, contribute code, and participate in the platform discussions.
## Code of conduct
To better foster an open, innovative and inclusive community please refer to our [Code of Conduct](CODE_OF_CONDUCT.md) when contributing.
### Report a bug
If you think you've found a bug, please log a new issue in the [Uno Core GitHub issue tracker](https://github.com/nventive/Uno.Core/issues). When filing issues, please use our [bug filing template](.github/ISSUE_TEMPLATE.md).
The best way to get your bug fixed is to be as detailed as you can be about the problem.
Providing a minimal project with steps to reproduce the problem is ideal.
Here are questions you can answer before you file a bug to make sure you're not missing any important information.
1. Did you read the [documentation](https://github.com/nventive/Uno.Core/blob/master/doc)?
2. Did you include the snippet of broken code in the issue?
3. What are the *EXACT* steps to reproduce this problem?
4. What specific version or build are you using?
5. What operating system are you using?
GitHub supports [markdown](https://help.github.com/articles/github-flavored-markdown/), so when filing bugs make sure you check the formatting before clicking submit.
### Make a suggestion
If you have an idea for a new feature or enhancement let us know by filing an [issue](https://github.com/nventive/Uno.Core/issues). To help us understand and prioritize your idea please provide as much detail about your scenario and why the feature or enhancement would be useful.
### Ask questions
If you have a question be sure to first checkout our [documentation](https://github.com/nventive/Uno.Core/blob/master/doc). But if you are still stuck, you'll have a better chance of getting help on [StackOverflow](https://stackoverflow.com/questions/tagged/uno-platform) and we'll do our best to answer it. Questions asked there should be tagged with `uno-platform`.
For a more direct conversation, [our gitter is also a good place to visit](https://gitter.im/uno-platform/Lobby).
## Contributing code and content
The Uno Platform is an open source project and we welcome code and content contributions from the community.
**Identifying the scale**
If you would like to contribute to one of our repositories, first identify the scale of what you would like to contribute. If it is small (grammar/spelling or a bug fix) feel free to start working on a fix.
If you are submitting a feature or substantial code contribution, please discuss it with the team. You might also read these two blogs posts on contributing code: [Open Source Contribution Etiquette](http://tirania.org/blog/archive/2010/Dec-31.html) by Miguel de Icaza and [Don't "Push" Your Pull Requests](https://www.igvita.com/2011/12/19/dont-push-your-pull-requests/) by Ilya Grigorik. Note that all code submissions will be rigorously reviewed and tested by the Uno Platform team, and only those that meet an extremely high bar for both quality and design/roadmap appropriateness will be merged into the source.
**Obtaining the source code**
If you are an outside contributer, please fork the Uno Core repository you would like to contribute to your account. See the GitHub documentation for [forking a repo](https://help.github.com/articles/fork-a-repo/) if you have any questions about this.
**Submitting a pull request**
If you don't know what a pull request is read this article: https://help.github.com/articles/using-pull-requests. Make sure the respository can build and all tests pass, as well as follow the current coding guidelines.
Pull requests should all be done to the **master** branch.
**Commit/Pull Request Format**
```
Summary of the changes (Less than 80 chars)
- Detail 1
- Detail 2
Addresses #bugnumber (in this specific format)
```
**Tests**
- Tests need to be provided for every bug/feature that is completed.
- Tests only need to be present for issues that need to be verified by QA (e.g. not tasks)
- If there is a scenario that is far too hard to test there does not need to be a test for it.
- "Too hard" is determined by the team as a whole.

209
License.md Normal file
Просмотреть файл

@ -0,0 +1,209 @@
# Uno.Core
Copyright (c) nventive
All rights reserved.
# Apache 2.0 License
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

59
README.md Normal file
Просмотреть файл

@ -0,0 +1,59 @@
# NuGet Package Diffing Tool
A command line tool that compares two versions of a NuGet package and provides public API differences.
This tool has originally been built to fail a build when a breaking change is detected, using a
published nuget package (in nuget.org) and a local NuGet package.
## Installing
Run the following command from command line (requires .NET Core 2.1 installed):
```
dotnet tool install --global Uno.PackageDiff
```
## Diffing packages
```
generatepkgdiff --base=Uno.UI --other=C:\temp\Uno.UI.1.43.0-PullRequest0621.917.nupkg --outfile=diff.md
```
The tool returns a non-zero value when differences are found, otherwise zero.
## How to provide an ignore set
The diff tool accepts a "ignore set" file which gives the ability to ignore specific differences. Those differences appear strike-out in the resulting markdown file.
Here's the format:
```xml
<DiffIgnore>
<IgnoreSets>
<IgnoreSet baseVersion="1.0.0">
<Types>
<Member fullName="MyNamespace.MyMissingClass" />
</Types>
<Properties>
<Member fullName="MyNamespace.MyClass.MyProperty" />
</Properties>
<Fields>
<Member fullName="MyNamespace.MyClass.myField" />
</Fields>
<Events>
<Member fullName="MyNamespace.MyClass.MyEvent" />
</Events>
<Methods>
<Member fullName="MyNamespace.MyClass.MyMethod" />
</Methods>
<Methods>
<Member fullName="MyNamespace.MyClass.MyMethod" />
</Methods>
</IgnoreSet>
</IgnoreSets>
</DiffIgnore>
```
The `baseVersion` attribute denotes the version for which the Ignore Set has been authored. This enables for the automatic discarding of existing sets when a new package version is published in nuget.org.
The `fullname` of members should be the exact string provided in the markdown file when a difference is identified.

21
gitversion.yml Normal file
Просмотреть файл

@ -0,0 +1,21 @@
assembly-versioning-scheme: MajorMinorPatch
mode: ContinuousDeployment
next-version: 1.0.0
continuous-delivery-fallback-tag: ""
branches:
master:
tag: dev
stable:
tag: ""
regex: stable
source-branches: ['master']
dev:
tag: dev.{BranchName}
regex: dev/.*?/(.*?)
source-branches: ['master']
projects:
tag: proj-{BranchName}
regex: projects/(.*?)
source-branches: ['master']
ignore:
sha: []

63
src/.gitattributes поставляемый Normal file
Просмотреть файл

@ -0,0 +1,63 @@
###############################################################################
# Set default behavior to automatically normalize line endings.
###############################################################################
* text=auto
###############################################################################
# Set default behavior for command prompt diff.
#
# This is need for earlier builds of msysgit that does not have it on by
# default for csharp files.
# Note: This is only used by command line
###############################################################################
#*.cs diff=csharp
###############################################################################
# Set the merge driver for project and solution files
#
# Merging from the command prompt will add diff markers to the files if there
# are conflicts (Merging from VS is not affected by the settings below, in VS
# the diff markers are never inserted). Diff markers may cause the following
# file extensions to fail to load in VS. An alternative would be to treat
# these files as binary and thus will always conflict and require user
# intervention with every merge. To do so, just uncomment the entries below
###############################################################################
#*.sln merge=binary
#*.csproj merge=binary
#*.vbproj merge=binary
#*.vcxproj merge=binary
#*.vcproj merge=binary
#*.dbproj merge=binary
#*.fsproj merge=binary
#*.lsproj merge=binary
#*.wixproj merge=binary
#*.modelproj merge=binary
#*.sqlproj merge=binary
#*.wwaproj merge=binary
###############################################################################
# behavior for image files
#
# image files are treated as binary by default.
###############################################################################
#*.jpg binary
#*.png binary
#*.gif binary
###############################################################################
# diff behavior for common document formats
#
# Convert binary document formats to text before diffing them. This feature
# is only available from the command line. Turn it on by uncommenting the
# entries below.
###############################################################################
#*.doc diff=astextplain
#*.DOC diff=astextplain
#*.docx diff=astextplain
#*.DOCX diff=astextplain
#*.dot diff=astextplain
#*.DOT diff=astextplain
#*.pdf diff=astextplain
#*.PDF diff=astextplain
#*.rtf diff=astextplain
#*.RTF diff=astextplain

340
src/.gitignore поставляемый Normal file
Просмотреть файл

@ -0,0 +1,340 @@
## Ignore Visual Studio temporary files, build results, and
## files generated by popular Visual Studio add-ons.
##
## Get latest from https://github.com/github/gitignore/blob/master/VisualStudio.gitignore
# User-specific files
*.rsuser
*.suo
*.user
*.userosscache
*.sln.docstates
# User-specific files (MonoDevelop/Xamarin Studio)
*.userprefs
# Build results
[Dd]ebug/
[Dd]ebugPublic/
[Rr]elease/
[Rr]eleases/
x64/
x86/
[Aa][Rr][Mm]/
[Aa][Rr][Mm]64/
bld/
[Bb]in/
[Oo]bj/
[Ll]og/
# Visual Studio 2015/2017 cache/options directory
.vs/
# Uncomment if you have tasks that create the project's static files in wwwroot
#wwwroot/
# Visual Studio 2017 auto generated files
Generated\ Files/
# MSTest test Results
[Tt]est[Rr]esult*/
[Bb]uild[Ll]og.*
# NUNIT
*.VisualState.xml
TestResult.xml
# Build Results of an ATL Project
[Dd]ebugPS/
[Rr]eleasePS/
dlldata.c
# Benchmark Results
BenchmarkDotNet.Artifacts/
# .NET Core
project.lock.json
project.fragment.lock.json
artifacts/
# StyleCop
StyleCopReport.xml
# Files built by Visual Studio
*_i.c
*_p.c
*_h.h
*.ilk
*.meta
*.obj
*.iobj
*.pch
*.pdb
*.ipdb
*.pgc
*.pgd
*.rsp
*.sbr
*.tlb
*.tli
*.tlh
*.tmp
*.tmp_proj
*_wpftmp.csproj
*.log
*.vspscc
*.vssscc
.builds
*.pidb
*.svclog
*.scc
# Chutzpah Test files
_Chutzpah*
# Visual C++ cache files
ipch/
*.aps
*.ncb
*.opendb
*.opensdf
*.sdf
*.cachefile
*.VC.db
*.VC.VC.opendb
# Visual Studio profiler
*.psess
*.vsp
*.vspx
*.sap
# Visual Studio Trace Files
*.e2e
# TFS 2012 Local Workspace
$tf/
# Guidance Automation Toolkit
*.gpState
# ReSharper is a .NET coding add-in
_ReSharper*/
*.[Rr]e[Ss]harper
*.DotSettings.user
# JustCode is a .NET coding add-in
.JustCode
# TeamCity is a build add-in
_TeamCity*
# DotCover is a Code Coverage Tool
*.dotCover
# AxoCover is a Code Coverage Tool
.axoCover/*
!.axoCover/settings.json
# Visual Studio code coverage results
*.coverage
*.coveragexml
# NCrunch
_NCrunch_*
.*crunch*.local.xml
nCrunchTemp_*
# MightyMoose
*.mm.*
AutoTest.Net/
# Web workbench (sass)
.sass-cache/
# Installshield output folder
[Ee]xpress/
# DocProject is a documentation generator add-in
DocProject/buildhelp/
DocProject/Help/*.HxT
DocProject/Help/*.HxC
DocProject/Help/*.hhc
DocProject/Help/*.hhk
DocProject/Help/*.hhp
DocProject/Help/Html2
DocProject/Help/html
# Click-Once directory
publish/
# Publish Web Output
*.[Pp]ublish.xml
*.azurePubxml
# Note: Comment the next line if you want to checkin your web deploy settings,
# but database connection strings (with potential passwords) will be unencrypted
*.pubxml
*.publishproj
# Microsoft Azure Web App publish settings. Comment the next line if you want to
# checkin your Azure Web App publish settings, but sensitive information contained
# in these scripts will be unencrypted
PublishScripts/
# NuGet Packages
*.nupkg
# The packages folder can be ignored because of Package Restore
**/[Pp]ackages/*
# except build/, which is used as an MSBuild target.
!**/[Pp]ackages/build/
# Uncomment if necessary however generally it will be regenerated when needed
#!**/[Pp]ackages/repositories.config
# NuGet v3's project.json files produces more ignorable files
*.nuget.props
*.nuget.targets
# Microsoft Azure Build Output
csx/
*.build.csdef
# Microsoft Azure Emulator
ecf/
rcf/
# Windows Store app package directories and files
AppPackages/
BundleArtifacts/
Package.StoreAssociation.xml
_pkginfo.txt
*.appx
# Visual Studio cache files
# files ending in .cache can be ignored
*.[Cc]ache
# but keep track of directories ending in .cache
!?*.[Cc]ache/
# Others
ClientBin/
~$*
*~
*.dbmdl
*.dbproj.schemaview
*.jfm
*.pfx
*.publishsettings
orleans.codegen.cs
# Including strong name files can present a security risk
# (https://github.com/github/gitignore/pull/2483#issue-259490424)
#*.snk
# Since there are multiple workflows, uncomment next line to ignore bower_components
# (https://github.com/github/gitignore/pull/1529#issuecomment-104372622)
#bower_components/
# RIA/Silverlight projects
Generated_Code/
# Backup & report files from converting an old project file
# to a newer Visual Studio version. Backup files are not needed,
# because we have git ;-)
_UpgradeReport_Files/
Backup*/
UpgradeLog*.XML
UpgradeLog*.htm
ServiceFabricBackup/
*.rptproj.bak
# SQL Server files
*.mdf
*.ldf
*.ndf
# Business Intelligence projects
*.rdl.data
*.bim.layout
*.bim_*.settings
*.rptproj.rsuser
*- Backup*.rdl
# Microsoft Fakes
FakesAssemblies/
# GhostDoc plugin setting file
*.GhostDoc.xml
# Node.js Tools for Visual Studio
.ntvs_analysis.dat
node_modules/
# Visual Studio 6 build log
*.plg
# Visual Studio 6 workspace options file
*.opt
# Visual Studio 6 auto-generated workspace file (contains which files were open etc.)
*.vbw
# Visual Studio LightSwitch build output
**/*.HTMLClient/GeneratedArtifacts
**/*.DesktopClient/GeneratedArtifacts
**/*.DesktopClient/ModelManifest.xml
**/*.Server/GeneratedArtifacts
**/*.Server/ModelManifest.xml
_Pvt_Extensions
# Paket dependency manager
.paket/paket.exe
paket-files/
# FAKE - F# Make
.fake/
# JetBrains Rider
.idea/
*.sln.iml
# CodeRush personal settings
.cr/personal
# Python Tools for Visual Studio (PTVS)
__pycache__/
*.pyc
# Cake - Uncomment if you are using it
# tools/**
# !tools/packages.config
# Tabs Studio
*.tss
# Telerik's JustMock configuration file
*.jmconfig
# BizTalk build output
*.btp.cs
*.btm.cs
*.odx.cs
*.xsd.cs
# OpenCover UI analysis results
OpenCover/
# Azure Stream Analytics local run output
ASALocalRun/
# MSBuild Binary and Structured Log
*.binlog
# NVidia Nsight GPU debugger configuration file
*.nvuser
# MFractors (Xamarin productivity tool) working folder
.mfractor/
# Local History for Visual Studio
.localhistory/
# BeatPulse healthcheck temp database
healthchecksdb

43
src/Directory.Build.props Normal file
Просмотреть файл

@ -0,0 +1,43 @@
<Project ToolsVersion="15.0">
<PropertyGroup>
<DebugType>portable</DebugType>
<DebugSymbols>True</DebugSymbols>
<RepositoryUrl>$(BUILD_REPOSITORY_URI)</RepositoryUrl>
<Copyright>nventive</Copyright>
<Author>nventive</Author>
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
<GenerateBindingRedirectsOutputType>true</GenerateBindingRedirectsOutputType>
<!-- Version management is now done through NuGet, this avoids issues related version mismatch -->
<Version>255.255.255.255</Version>
<Product>$(AssemblyName) ($(TargetFramework))</Product>
<DefaultLanguage>en-US</DefaultLanguage>
<UnoSourceGeneratorUseGenerationHost>true</UnoSourceGeneratorUseGenerationHost>
</PropertyGroup>
<PropertyGroup>
<IsTestProject>$(MSBuildProjectName.Contains('Test'))</IsTestProject>
<IsSampleProject>$(MSBuildProjectName.Contains('Sample'))</IsSampleProject>
</PropertyGroup>
<Choose>
<When Condition="'$(Configuration)' != 'Debug' and '$(IsTestProject)' != 'true' and '$(SourceLinkEnabled)' != 'false' and '$(IsSampleProject)' != 'true'">
<PropertyGroup>
<!-- Optional: Declare that the Repository URL can be published to NuSpec -->
<PublishRepositoryUrl>true</PublishRepositoryUrl>
<!-- Optional: Embed source files that are not tracked by the source control manager to the PDB -->
<EmbedUntrackedSources>true</EmbedUntrackedSources>
<!-- Optional: Include PDB in the built .nupkg -->
<AllowedOutputExtensionsInPackageBuildOutputFolder>$(AllowedOutputExtensionsInPackageBuildOutputFolder);.pdb</AllowedOutputExtensionsInPackageBuildOutputFolder>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Microsoft.SourceLink.Vsts.Git" Version="1.0.0-beta-62925-02" PrivateAssets="All"/>
<PackageReference Include="Microsoft.SourceLink.GitHub" Version="1.0.0-beta-62925-02" PrivateAssets="All"/>
</ItemGroup>
</When>
</Choose>
</Project>

Просмотреть файл

@ -0,0 +1,3 @@
<Project ToolsVersion="15.0">
</Project>

27
src/uno.uitest.sln Normal file
Просмотреть файл

@ -0,0 +1,27 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 16
VisualStudioVersion = 16.0.28902.138
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Uno.UITest", "uno.uitest\Uno.UITest.csproj", "{C0578553-D584-48C3-9484-1A25DAD66269}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Samples", "Samples", "{CD1416B0-9C18-47C1-8B73-34582BAB0EE6}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{C0578553-D584-48C3-9484-1A25DAD66269}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{C0578553-D584-48C3-9484-1A25DAD66269}.Debug|Any CPU.Build.0 = Debug|Any CPU
{C0578553-D584-48C3-9484-1A25DAD66269}.Release|Any CPU.ActiveCfg = Release|Any CPU
{C0578553-D584-48C3-9484-1A25DAD66269}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {8151C9E9-B16D-46FF-B9AB-8E19B32E1B4F}
EndGlobalSection
EndGlobal

Просмотреть файл

@ -0,0 +1,25 @@
namespace Uno.UITest
{
public interface IAppWebRect
{
float Width { get; set; }
float Height { get; set; }
float CenterX { get; set; }
float CenterY { get; set; }
float Top { get; set; }
float Bottom { get; set; }
float Left { get; set; }
float Right { get; set; }
float X { get; set; }
float Y { get; set; }
}
}

8
src/uno.uitest/Class1.cs Normal file
Просмотреть файл

@ -0,0 +1,8 @@
using System;
namespace uno.uitest
{
public class Class1
{
}
}

92
src/uno.uitest/IApp.cs Normal file
Просмотреть файл

@ -0,0 +1,92 @@
using System;
using System.Collections.Generic;
using System.IO;
using System.Text;
namespace Uno.UITest
{
public interface IApp
{
IDevice Device { get; }
void Back();
void ClearText();
void ClearText(string marked);
void ClearText(Func<IAppQuery, IAppQuery> query);
void ClearText(Func<IAppQuery, IAppWebQuery> query);
void DismissKeyboard();
void DoubleTap(Func<IAppQuery, IAppQuery> query);
void DoubleTap(string marked);
void DoubleTapCoordinates(float x, float y);
void DragAndDrop(Func<IAppQuery, IAppQuery> from, Func<IAppQuery, IAppQuery> to);
void DragAndDrop(string from, string to);
void DragCoordinates(float fromX, float fromY, float toX, float toY);
void EnterText(string marked, string text);
void EnterText(string text);
void EnterText(Func<IAppQuery, IAppWebQuery> query, string text);
void EnterText(Func<IAppQuery, IAppQuery> query, string text);
IAppResult[] Flash(string marked);
IAppResult[] Flash(Func<IAppQuery, IAppQuery> query = null);
object Invoke(string methodName, object[] arguments);
object Invoke(string methodName, object argument = null);
void PinchToZoomIn(string marked, TimeSpan? duration = null);
void PinchToZoomIn(Func<IAppQuery, IAppQuery> query, TimeSpan? duration = null);
void PinchToZoomInCoordinates(float x, float y, TimeSpan? duration);
void PinchToZoomOut(string marked, TimeSpan? duration = null);
void PinchToZoomOut(Func<IAppQuery, IAppQuery> query, TimeSpan? duration = null);
void PinchToZoomOutCoordinates(float x, float y, TimeSpan? duration);
void PressEnter();
void PressVolumeDown();
void PressVolumeUp();
IAppResult[] Query(Func<IAppQuery, IAppQuery> query = null);
string[] Query(Func<IAppQuery, IInvokeJSAppQuery> query);
IAppResult[] Query(string marked);
IAppWebResult[] Query(Func<IAppQuery, IAppWebQuery> query);
T[] Query<T>(Func<IAppQuery, IAppTypedSelector<T>> query);
void Repl();
FileInfo Screenshot(string title);
void ScrollDown(string withinMarked, ScrollStrategy strategy = ScrollStrategy.Auto, double swipePercentage = 0.67, int swipeSpeed = 500, bool withInertia = true);
void ScrollDown(Func<IAppQuery, IAppQuery> withinQuery = null, ScrollStrategy strategy = ScrollStrategy.Auto, double swipePercentage = 0.67, int swipeSpeed = 500, bool withInertia = true);
void ScrollDownTo(Func<IAppQuery, IAppWebQuery> toQuery, Func<IAppQuery, IAppQuery> withinQuery = null, ScrollStrategy strategy = ScrollStrategy.Auto, double swipePercentage = 0.67, int swipeSpeed = 500, bool withInertia = true, TimeSpan? timeout = null);
void ScrollDownTo(Func<IAppQuery, IAppQuery> toQuery, Func<IAppQuery, IAppQuery> withinQuery = null, ScrollStrategy strategy = ScrollStrategy.Auto, double swipePercentage = 0.67, int swipeSpeed = 500, bool withInertia = true, TimeSpan? timeout = null);
void ScrollDownTo(Func<IAppQuery, IAppWebQuery> toQuery, string withinMarked, ScrollStrategy strategy = ScrollStrategy.Auto, double swipePercentage = 0.67, int swipeSpeed = 500, bool withInertia = true, TimeSpan? timeout = null);
void ScrollDownTo(string toMarked, string withinMarked = null, ScrollStrategy strategy = ScrollStrategy.Auto, double swipePercentage = 0.67, int swipeSpeed = 500, bool withInertia = true, TimeSpan? timeout = null);
void ScrollTo(string toMarked, string withinMarked = null, ScrollStrategy strategy = ScrollStrategy.Auto, double swipePercentage = 0.67, int swipeSpeed = 500, bool withInertia = true, TimeSpan? timeout = null);
void ScrollUp(Func<IAppQuery, IAppQuery> query = null, ScrollStrategy strategy = ScrollStrategy.Auto, double swipePercentage = 0.67, int swipeSpeed = 500, bool withInertia = true);
void ScrollUp(string withinMarked, ScrollStrategy strategy = ScrollStrategy.Auto, double swipePercentage = 0.67, int swipeSpeed = 500, bool withInertia = true);
void ScrollUpTo(Func<IAppQuery, IAppQuery> toQuery, Func<IAppQuery, IAppQuery> withinQuery = null, ScrollStrategy strategy = ScrollStrategy.Auto, double swipePercentage = 0.67, int swipeSpeed = 500, bool withInertia = true, TimeSpan? timeout = null);
void ScrollUpTo(Func<IAppQuery, IAppWebQuery> toQuery, Func<IAppQuery, IAppQuery> withinQuery = null, ScrollStrategy strategy = ScrollStrategy.Auto, double swipePercentage = 0.67, int swipeSpeed = 500, bool withInertia = true, TimeSpan? timeout = null);
void ScrollUpTo(Func<IAppQuery, IAppWebQuery> toQuery, string withinMarked, ScrollStrategy strategy = ScrollStrategy.Auto, double swipePercentage = 0.67, int swipeSpeed = 500, bool withInertia = true, TimeSpan? timeout = null);
void ScrollUpTo(string toMarked, string withinMarked = null, ScrollStrategy strategy = ScrollStrategy.Auto, double swipePercentage = 0.67, int swipeSpeed = 500, bool withInertia = true, TimeSpan? timeout = null);
void SetOrientationLandscape();
void SetOrientationPortrait();
void SetSliderValue(string marked, double value);
void SetSliderValue(Func<IAppQuery, IAppQuery> query, double value);
void SwipeLeftToRight(Func<IAppQuery, IAppWebQuery> query, double swipePercentage = 0.67, int swipeSpeed = 500, bool withInertia = true);
void SwipeLeftToRight(string marked, double swipePercentage = 0.67, int swipeSpeed = 500, bool withInertia = true);
void SwipeLeftToRight(double swipePercentage = 0.67, int swipeSpeed = 500, bool withInertia = true);
void SwipeLeftToRight(Func<IAppQuery, IAppQuery> query, double swipePercentage = 0.67, int swipeSpeed = 500, bool withInertia = true);
void SwipeRightToLeft(double swipePercentage = 0.67, int swipeSpeed = 500, bool withInertia = true);
void SwipeRightToLeft(Func<IAppQuery, IAppWebQuery> query, double swipePercentage = 0.67, int swipeSpeed = 500, bool withInertia = true);
void SwipeRightToLeft(Func<IAppQuery, IAppQuery> query, double swipePercentage = 0.67, int swipeSpeed = 500, bool withInertia = true);
void SwipeRightToLeft(string marked, double swipePercentage = 0.67, int swipeSpeed = 500, bool withInertia = true);
void Tap(string marked);
void Tap(Func<IAppQuery, IAppWebQuery> query);
void Tap(Func<IAppQuery, IAppQuery> query);
void TapCoordinates(float x, float y);
void TouchAndHold(Func<IAppQuery, IAppQuery> query);
void TouchAndHold(string marked);
void TouchAndHoldCoordinates(float x, float y);
void WaitFor(Func<bool> predicate, string timeoutMessage = "Timed out waiting...", TimeSpan? timeout = null, TimeSpan? retryFrequency = null, TimeSpan? postTimeout = null);
IAppWebResult[] WaitForElement(Func<IAppQuery, IAppWebQuery> query, string timeoutMessage = "Timed out waiting for element...", TimeSpan? timeout = null, TimeSpan? retryFrequency = null, TimeSpan? postTimeout = null);
IAppResult[] WaitForElement(string marked, string timeoutMessage = "Timed out waiting for element...", TimeSpan? timeout = null, TimeSpan? retryFrequency = null, TimeSpan? postTimeout = null);
IAppResult[] WaitForElement(Func<IAppQuery, IAppQuery> query, string timeoutMessage = "Timed out waiting for element...", TimeSpan? timeout = null, TimeSpan? retryFrequency = null, TimeSpan? postTimeout = null);
void WaitForNoElement(Func<IAppQuery, IAppQuery> query, string timeoutMessage = "Timed out waiting for no element...", TimeSpan? timeout = null, TimeSpan? retryFrequency = null, TimeSpan? postTimeout = null);
void WaitForNoElement(string marked, string timeoutMessage = "Timed out waiting for no element...", TimeSpan? timeout = null, TimeSpan? retryFrequency = null, TimeSpan? postTimeout = null);
void WaitForNoElement(Func<IAppQuery, IAppWebQuery> query, string timeoutMessage = "Timed out waiting for no element...", TimeSpan? timeout = null, TimeSpan? retryFrequency = null, TimeSpan? postTimeout = null);
}
}

Просмотреть файл

@ -0,0 +1,51 @@
using System;
using System.Collections.Generic;
using System.Text;
namespace Uno.UITest
{
public interface IAppQuery
{
IAppQuery All(string className = null);
IAppQuery Button(string marked = null);
IAppQuery Child(string className = null);
IAppQuery Child(int index);
IAppQuery Class(string className);
IAppQuery ClassFull(string className);
IAppQuery Descendant(int index);
IAppQuery Descendant(string className = null);
IAppQuery Frame(string cssSelector);
IAppQuery Id(string id);
IAppQuery Id(int id);
IAppQuery Index(int index);
IAppTypedSelector<object> Invoke(string methodName, object arg1, object arg2, object arg3, object arg4);
IAppTypedSelector<object> Invoke(string methodName, object arg1, object arg2, object arg3, object arg4, object arg5);
IAppTypedSelector<object> Invoke(string methodName);
IAppTypedSelector<object> Invoke(string methodName, object arg1, object arg2, object arg3);
IAppTypedSelector<object> Invoke(string methodName, object arg1);
IAppTypedSelector<object> Invoke(string methodName, object arg1, object arg2);
IInvokeJSQuery InvokeJS(string javascript);
IAppQuery Marked(string text);
IAppQuery Parent(string className = null);
IAppQuery Parent(int index);
IPropertyQuery Property(string propertyName);
IAppQuery Property(string propertyName, string value);
IAppQuery Property(string propertyName, bool value);
IAppQuery Property(string propertyName, int value);
IAppTypedSelector<string> Raw(string calabashQuery, object arg1, object arg2, object arg3, object arg4, object arg5);
IAppTypedSelector<string> Raw(string calabashQuery, object arg1, object arg2, object arg3, object arg4, object arg5, object arg6);
IAppTypedSelector<string> Raw(string calabashQuery, object arg1, object arg2, object arg3);
IAppTypedSelector<string> Raw(string calabashQuery, object arg1, object arg2);
IAppQuery Raw(string calabashQuery);
IAppTypedSelector<string> Raw(string calabashQuery, object arg1, object arg2, object arg3, object arg4);
IAppTypedSelector<string> Raw(string calabashQuery, object arg1);
IAppQuery Sibling(int index);
IAppQuery Sibling(string className = null);
IAppQuery Switch(string marked = null);
IAppQuery Text(string text);
IAppQuery TextField(string marked = null);
IAppQuery WebView();
IAppQuery WebView(int index);
IAppWebQuery XPath(string xPathSelector);
}
}

Просмотреть файл

@ -0,0 +1,6 @@
namespace Uno.UITest
{
public interface IAppResult
{
}
}

Просмотреть файл

@ -0,0 +1,19 @@
namespace Uno.UITest
{
public interface IAppTypedSelector<T>
{
IAppTypedSelector<object> Invoke(string methodName);
IAppTypedSelector<object> Invoke(string methodName, object arg1);
IAppTypedSelector<object> Invoke(string methodName, object arg1, object arg2);
IAppTypedSelector<object> Invoke(string methodName, object arg1, object arg2, object arg3);
IAppTypedSelector<object> Invoke(string methodName, object arg1, object arg2, object arg3, object arg4);
IAppTypedSelector<object> Invoke(string methodName, object arg1, object arg2, object arg3, object arg4, object arg5);
IAppTypedSelector<TResult> Value<TResult>();
}
}

Просмотреть файл

@ -0,0 +1,8 @@
namespace Uno.UITest
{
public interface IAppWebQuery
{
IAppWebQuery Index(int index);
string ToString();
}
}

Просмотреть файл

@ -0,0 +1,23 @@
namespace Uno.UITest
{
public interface IAppWebResult
{
string Id { get; set; }
string NodeType { get; set; }
string NodeName { get; set; }
string Class { get; set; }
string Html { get; set; }
string Value { get; set; }
string WebView { get; set; }
string TextContent { get; set; }
IAppWebRect Rect { get; set; }
}
}

13
src/uno.uitest/IDevice.cs Normal file
Просмотреть файл

@ -0,0 +1,13 @@
using System;
namespace Uno.UITest
{
public interface IDevice
{
Uri DeviceUri { get; }
string DeviceIdentifier { get; }
void SetLocation(double latitude, double longitude);
}
}

Просмотреть файл

@ -0,0 +1,8 @@
namespace Uno.UITest
{
public interface IInvokeJSAppQuery
{
string Javascript { get; }
IAppQuery AppQuery { get; }
}
}

Просмотреть файл

@ -0,0 +1,19 @@
namespace Uno.UITest
{
public interface IPropertyQuery
{
QueryPlatform QueryPlatform { get; }
IAppQuery Contains(string text);
IAppQuery EndsWith(string text);
IAppQuery Like(string text);
IAppQuery Predicate(string predicate, string text);
IAppQuery StartsWith(string text);
IAppTypedSelector<T> Value<T>();
}
}

Просмотреть файл

@ -0,0 +1,9 @@
namespace Uno.UITest
{
public enum QueryPlatform
{
Android = 0,
iOS = 1,
WebAssembly = 10,
}
}

Просмотреть файл

@ -0,0 +1,9 @@
namespace Uno.UITest
{
public enum ScrollStrategy
{
Auto = 0,
Programmatically = 1,
Gesture = 2
}
}

Просмотреть файл

@ -0,0 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>netstandard2.0</TargetFramework>
</PropertyGroup>
</Project>