有没有办法隐藏Typemock Isolator一旦安装后添加到Visual Studio编辑器窗口的巨大符号 - 顶部的橙色屏蔽和每个方法附近的橙色/绿色屏蔽?我不需要它们,因为我正在使用其他测试跑步者,但我还没有找到隐藏它们的方法.
unit-testing typemock visual-studio-2010 visual-studio-2008 visual-studio-2012
有时我不想在开发过程中将所有内容都记录到 Visual Studio 输出窗口(目标 --> 调试器)中。我想也许有一种方法可以命名一个特定的记录器(一个类)或几个记录器(来自多个类),以便在配置文件中我可以只为我目前感兴趣的开发类启用日志记录。
目前,我在所有课程中都有这个最常见的 NLog 行:
private static readonly NLog.Logger logger = NLog.LogManager.GetCurrentClassLogger();
Run Code Online (Sandbox Code Playgroud)
以及一个非常标准的配置,它只是将日志呈现到输出窗口。
不幸的是,我没有找到如何按类启用/禁用记录器。
如何使用 bootstrap 4 modals 作为“block ui”功能:在 AJAX 调用中动态淡入淡出屏幕(并在那个时刻显示“等一下......”标签或沙镜)?
如果您在框架中有模态,这意味着您也可以使用它们来阻止 UI 功能。但是我在官方文档中找不到任何 API 或示例...
我有一个运行良好的WSDL服务(并且仍在.net 4.x中运行),并且是.NET Core 2.0的新手。
我创建了WSDL Web服务参考(与https://docs.microsoft.com/en-us/dotnet/core/additional-tools/wcf-web-service-reference-guide相同的步骤)
我的问题是如何使用这项服务?有人知道好的教程吗?任何帮助将不胜感激。
先感谢您
我正在尝试将自定义图标添加到 Visual Studio 中的解决方案资源管理器,就像FileIcons 扩展一样。
我认为我已经为 Visual Studio 做了所有正确的事情,将新图标与以.d和.di扩展名结尾的文件关联起来,但 Visual Studio 仍然没有在解决方案资源管理器中显示任何图标。
这是使用以下命令生成的清单ManifestFromResources.exe:
<?xml version="1.0" encoding="utf-8"?>
<!-- This file was generated by the ManifestFromResources tool.-->
<!-- Version: 14.0.50929.2 -->
<ImageManifest xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://schemas.microsoft.com/VisualStudio/ImageManifestSchema/2014">
<Symbols>
<String Name="Resources" Value="/VisualDLS;Component/Icons" />
<Guid Name="AssetsGuid" Value="{872b4702-eabf-444b-b6b3-96dc64531f74}" />
<ID Name="d" Value="0" />
</Symbols>
<Images>
<Image Guid="$(AssetsGuid)" ID="$(d)">
<Source Uri="$(Resources)/d.png">
<Size Value="32" />
</Source>
</Image>
</Images>
<ImageLists />
</ImageManifest>
Run Code Online (Sandbox Code Playgroud)
这是 pkgdef 文件:
[$RootKey$\ShellFileAssociations\.d]
"DefaultIconMoniker"="872b4702-eabf-444b-b6b3-96dc64531f74:0"
[$RootKey$\ShellFileAssociations\.di]
"DefaultIconMoniker"="872b4702-eabf-444b-b6b3-96dc64531f74:0"
Run Code Online (Sandbox Code Playgroud)
在我的扩展的 vsixmanifest 中,pkgdef …
icons visual-studio solution-explorer visual-studio-extensions
使用Babel 7(针对模块UMD配置)
import '@babel/polyfill';
import Popper from 'popper.js';
Run Code Online (Sandbox Code Playgroud)
被移植到
(function (global, factory) {
if (typeof define === "function" && define.amd) {
//...
} else {
var mod = {
exports: {}
};
factory(global.polyfill, global.popper);
global.site = mod.exports;
}
})(/* ... */);
Run Code Online (Sandbox Code Playgroud)
当popper.js lib在global中将自身定义为global.Poopper时,global.popper用小写字母表示-第一个字母用大写字母表示。
一年前,我已经读过一些有关此类UMD问题的信息-但现在在Internet上找不到详细信息。因此,请向我说明如何避免此类问题(不使用Rollup及其工具)。
PS global.polyfill也是胡说八道。
实际上,我只是想在没有webpack的情况下使用Babel和以“旧方式”使用requirejs-将文件逐个文件传输到js文件夹,然后使用加载每个脚本<script>。正如对其工具的研究一样。但这是很难的。
我是asp.net核心的新手。我正在尝试在一段时间不活动后实施用户注销。有人可以建议指南/教程或解释如何使用 asp.net core 2.0 和 MySql 而不是实体框架来实现这一点。
当调试过程打开 Razor 文件时,无法进行下一步(F10、F11),因为 VS 被错误“文件已修改:继续或停止”阻止。此消息还会出现在 VS 错误列表中:
使用“修改后的”剃刀文件关闭选项卡在某种程度上有所帮助 - 错误消失了 - 然后可以继续调试。
看起来 VS 自己更改了文件,但除了这条消息之外没有任何迹象。
VS 为什么以及在哪里添加这个“命名空间”?知道这一点后,我会自己将这个“命名空间”添加到我的代码中,然后 VS 将没有理由更改代码并中断调试。
我已经从备份中还原了Gitlab,现在每次尝试访问该runners网页时,我都会收到内部服务器错误。
我尝试卸载所有配置的gitlab-runners并访问它,问题仍然存在。这是gitlab-rails / production.log中的跟踪:
Started GET "/admin/runners" for 127.0.0.1 at 2019-01-16 07:17:12 -0500
Processing by Admin::RunnersController#index as HTML
Completed 500 Internal Server Error in 66ms (ActiveRecord: 5.7ms)
ActionView::Template::Error ():
37:
38: .col-sm-6
39: .bs-callout
40: = render partial: 'ci/runner/how_to_setup_runner',
41: locals: { registration_token: Gitlab::CurrentSettings.runners_registration_token,
42: type: 'shared',
43: reset_token_url: reset_registration_token_admin_application_settings_path }
lib/gitlab/crypto_helper.rb:27:in `aes256_gcm_decrypt'
app/models/concerns/token_authenticatable_strategies/encrypted.rb:55:in `get_token'
app/models/concerns/token_authenticatable_strategies/base.rb:33:in `ensure_token!'
app/models/concerns/token_authenticatable.rb:43:in `block in add_authentication_token_field'
app/models/application_setting.rb:409:in `runners_registration_token'
lib/gitlab/current_settings.rb:19:in `method_missing'
app/views/admin/runners/index.html.haml:40:in `_app_views_admin_runners_index_html_haml___977288809002382166_69944849285200'
app/controllers/application_controller.rb:116:in `render'
lib/gitlab/i18n.rb:55:in `with_locale'
lib/gitlab/i18n.rb:61:in `with_user_locale'
app/controllers/application_controller.rb:420:in `set_locale'
lib/gitlab/middleware/multipart.rb:103:in `call'
lib/gitlab/request_profiler/middleware.rb:16:in …Run Code Online (Sandbox Code Playgroud) 结构:
+ MyProj
+ Areas
+ Configuration
- Pages
- ConfigurationApiController.cs
Run Code Online (Sandbox Code Playgroud)
VS2017建议创建不带Controllers文件夹的控制器,这对我来说是可以的,因为我使用Razor Pages并且不需要Controllers文件夹:
那些不起作用:
控制器定义:
+ MyProj
+ Areas
+ Configuration
- Pages
- ConfigurationApiController.cs
Run Code Online (Sandbox Code Playgroud)
Mvc路由配置的标准方式:
[Route("api")]
[Produces("application/json")]
[ApiController]
public class ConfigurationApiController : ControllerBase
{
private readonly ApplicationSettings applicationSettings;
[HttpGet]
public ActionResult GetUsers()
{
Run Code Online (Sandbox Code Playgroud)
如何GetUsers采取行动ConfigurationApiController?
asp.net-core asp.net-core-webapi razor-pages asp.net-core-2.2
asp.net-core ×3
.net ×1
.net-core ×1
asp.net-mvc ×1
babel ×1
blockui ×1
bootstrap-4 ×1
c# ×1
gitlab ×1
gitlab-ce ×1
icons ×1
javascript ×1
modal-dialog ×1
mysql ×1
nlog ×1
razor-pages ×1
typemock ×1
umd ×1
unit-testing ×1
wcf ×1