首页 文章 精选 留言 我的

精选列表

搜索[.NET框架],共10000篇文章
优秀的个人博客,低调大师

Java JUnit框架里@Category注解的工作原理

Suppose you have a large number of unit test cases and you don’t want them to be executed all at the same time during Maven build. You can simply achieve it via annotation @Category. (1) Create empty class FastTests and SlowTests.(2) In your test case class, categorize your test method using @Category annotation: (3) Append the following code to your pom.xml: <profiles> <profile> <id>SlowTests</id> <properties> <testcase.groups>com.sap.SlowTests</testcase.groups> </properties> </profile> <profile> <id>FastTests</id> <properties> <testcase.groups>com.sap.FastTests</testcase.groups> </properties> </profile> </profiles> <build> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-compiler-plugin</artifactId> <version>3.1</version> <configuration> <source>1.8</source> <target>1.8</target> </configuration> </plugin> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-surefire-plugin</artifactId> <version>2.13</version> <dependencies> <dependency> <groupId>org.apache.maven.surefire</groupId> <artifactId>surefire-junit47</artifactId> <version>2.13</version> </dependency> </dependencies> <configuration> <groups>${testcase.groups}</groups> </configuration> </plugin> </plugins> </build> (4) In my project, by default all 7 test methods will be executed during Maven build: Suppose you only want to execute unit test belonging to category “SlowTests”, use the following command line: Since now I only marked one method with annotation SlowTests, only one test method is executed: If you would like to execute all unit tests EXCEPT @SlowTests, simply add another profile in pom.xml: <profile> <id>NonSlowTests</id> <build> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-surefire-plugin</artifactId> <configuration> <excludedGroups>com.sap.SlowTests</excludedGroups> </configuration> </plugin> </plugins> </build> </profile> Before test, in order to prove that Slow method is NOT really executed, I add a system.out.println in each method: Use command line: mvn test -P NonSlowTestsFrom console output, I can ensure that the method with @Category(SlowTests.class) is NOT executed at all. 本文来自云栖社区合作伙伴“汪子熙”,了解相关信息可以关注微信公众号"汪子熙"。

优秀的个人博客,低调大师

Apache ZooKeeper 3.6.1 发布,分布式服务框架

Apache ZooKeeper 3.6.1 已发布,这是 3.6 分支的第二个版本,也是一个 bugfix 版本,修复了针对 ZooKeeper 3.5 构建的应用程序有关的一些兼容性问题。从 3.5.7 升级到 3.6.1 像往常一样执行即可,无需特别的附加升级程序。只要不使用 3.5 中不存在的新 API,ZooKeeper 3.6.1 客户端与 3.5 服务器兼容。 新特性 ZOOKEEPER-3689- zkCli/ZooKeeperMain 依赖系统属性来进行 TLS 配置 ZOOKEEPER-3712- 为 NIOServerCnxn 添加 setKeepAlive 支持 改进 ZOOKEEPER-3685- 将JDK Arrays Equals 用于 Jute 编译器 ZOOKEEPER-3686- 将JDK Arrays hashCode 用于 Jute 编译器 ZOOKEEPER-3708- 在 Learner 中,将日志代码移动至 Logging Guard ZOOKEEPER-3741- 修复在 Fedora8 上构建 ZooKeeper 3.5 C 客户端出现的问题 ZOOKEEPER-3755- 使用maven 来创建 fatjar ZOOKEEPER-3756- 修复成员不能成功 rejoin quorum 的问题 ZOOKEEPER-3785- 支持使用 JDK14 进行构建源码 详情查看https://zookeeper.apache.org/doc/r3.6.1/releasenotes.html 下载地址https://zookeeper.apache.org/releases.html#download

优秀的个人博客,低调大师

Angular 10.0.0-next.2 发布,Web 前端框架

Angular 10.0.0-next.2已发布,具体更新内容如下: Bug Fixes common:locales/global/*.js不符合 ES5(#36342)(078b0be),closesangular / angular-cli#16394 compiler:正确处理对命名空间符号的类型引用(#36106)(4aa4e6f),closes#36006 core:如果 base class 没有 value 声明,则具有修饰字段的未修饰类迁移应避免 error(#36543)(ca67748),closes#36522 ngcc:从嵌套node_modules/中正确检测外部文件(#36559)(6ab43d7),closes#36526 ngcc:在 Windows 上显示解锁程序的输出(#36569)(e041ac6) ngcc:不要在 cluster workers上生成解锁程序(#36569)(66effde),closes#35861 ngcc:如果paths映射不存在(#36525)(717df13),则不发出警告,closes#36518 ngcc:强制 ngcc 错误退出(#36622)(663b768),closes#36616 router:使用两个或多个同级路由器出口时,将正确的组件传递给 canDeactivate 检查(#36302)(80e6c07),closes#34614 upgrade:更新$locationShim 以在初始化之前处理位置更改(#36498)(0cc53fb),closes#36492 Performance Improvements ngcc:仅在需要时加载(#36486)(3bedfda) ngcc:从 entry-point manifest 中读取依赖项(#36486)(a185efb),closes#issuecomment-608401834 ngcc:减少 entry-point manifest 文件的大小(#36486)(ec0ce60) 更新说明:https://github.com/angular/angular/blob/master/CHANGELOG.md

优秀的个人博客,低调大师

Fastify 2.12.1 发布,高性能 Node.js 框架

Fastify 2.12.1 发布了。 添加了 fastify-esso 插件(#2084) 将逗号添加到 queryStringJsonSchema(#2085) 如果发送了无效的状态代码,则会引发错误(#2082) Greenkeeper 忽略 semver(#2095) 修复setErrorHandler(#2092)的错误类型 修复了typo res.res to Reply.res(#2099) docs:将属性分配给请求时使用计算键(#2100) 类型:将类型添加this到未找到的处理程序中(#2102) docs:修复标头和正文泛型类型(#2103) 修复:多个路由相同的架构(#2108) http2:未设置修复req.hostname(#2113) 添加了fastify-axios插件(#2118) docs:澄清 reply.redirect 状态代码文件(#2121)

优秀的个人博客,低调大师

Cutter 1.10.1 发布,C 语言单元测试框架

Cutter 1.10.1现已发布,该版本更新内容如下: Highlights 现在默认在所有平台上都提供 r2dec 反编译器 radre2 已更新至最新版本-v4.2.1 整个 Cutter 的主要性能改进 从标志和函数中删除前缀以使其更漂亮 新对话框可设置和编辑断点,包括硬件和条件断点 插件作者的 API改进 更快,更好地伸缩Stack和Registers 各种 bug 修复和小改进 Additions 将 r2dec 捆绑到 macOS 和 Linux 构建中(#2023,#2033) 将实名和 libname 添加到 Flags and Imports 小部件(#2024) 添加断点编辑器对话框(#1975) 添加更多断点编辑选项(#1967) 添加用于插件的 API 以扩展上下文菜单(#2029) 添加自定义伸缩功能并改善 StackWidget 的输出(#1990) ...... Fixes and Changes 将 radare2 更新为 4.2.1(#2040) 简化插件上下文菜单 GUI 代码并将其移出核心。(#2039) 将设置中的用户插件路径设置为链接(#2034) 改善图表上的默认线宽值(#2026) 如果可用,请将 r2ghidra 设置为默认的反编译器(#2007) 提高标志和字符串小部件的性能(#2021) 打开外观设置时设置缩放倍数。(#2003) ...... 更多详细信息可查看更新说明:https://github.com/radareorg/cutter/releases

资源下载

更多资源
Mario

Mario

马里奥是站在游戏界顶峰的超人气多面角色。马里奥靠吃蘑菇成长,特征是大鼻子、头戴帽子、身穿背带裤,还留着胡子。与他的双胞胎兄弟路易基一起,长年担任任天堂的招牌角色。

腾讯云软件源

腾讯云软件源

为解决软件依赖安装时官方源访问速度慢的问题,腾讯云为一些软件搭建了缓存服务。您可以通过使用腾讯云软件源站来提升依赖包的安装速度。为了方便用户自由搭建服务架构,目前腾讯云软件源站支持公网访问和内网访问。

Nacos

Nacos

Nacos /nɑ:kəʊs/ 是 Dynamic Naming and Configuration Service 的首字母简称,一个易于构建 AI Agent 应用的动态服务发现、配置管理和AI智能体管理平台。Nacos 致力于帮助您发现、配置和管理微服务及AI智能体应用。Nacos 提供了一组简单易用的特性集,帮助您快速实现动态服务发现、服务配置、服务元数据、流量管理。Nacos 帮助您更敏捷和容易地构建、交付和管理微服务平台。

Spring

Spring

Spring框架(Spring Framework)是由Rod Johnson于2002年提出的开源Java企业级应用框架,旨在通过使用JavaBean替代传统EJB实现方式降低企业级编程开发的复杂性。该框架基于简单性、可测试性和松耦合性设计理念,提供核心容器、应用上下文、数据访问集成等模块,支持整合Hibernate、Struts等第三方框架,其适用范围不仅限于服务器端开发,绝大多数Java应用均可从中受益。

用户登录
用户注册
修改密码
忘记密码