-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: cocosip <1185513330@qq.com>
- Loading branch information
Showing
3 changed files
with
19 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +1,27 @@ | ||
using DotCommon.Utility; | ||
using System; | ||
using System.Collections.Generic; | ||
using System.Text; | ||
using Xunit; | ||
|
||
namespace DotCommon.Test.Utility | ||
{ | ||
public class BufferQueueTest | ||
{ | ||
[Fact] | ||
public void BufferQueue_Test() | ||
{ | ||
var r = 0; | ||
var queue = new BufferQueue<int>("q1", 2, v => | ||
{ | ||
r = v; | ||
}); | ||
queue.EnqueueMessage(1); | ||
queue.EnqueueMessage(2); | ||
queue.EnqueueMessage(3); | ||
queue.EnqueueMessage(4); | ||
queue.EnqueueMessage(5); | ||
|
||
Assert.True(r > 0); | ||
//[Fact] | ||
//public void BufferQueue_Test() | ||
//{ | ||
// var r = 0; | ||
// var queue = new BufferQueue<int>("q1", 2, v => | ||
// { | ||
// r = v; | ||
// }); | ||
// queue.EnqueueMessage(1); | ||
// queue.EnqueueMessage(2); | ||
// queue.EnqueueMessage(3); | ||
// queue.EnqueueMessage(4); | ||
// queue.EnqueueMessage(5); | ||
|
||
} | ||
// Assert.True(r > 0); | ||
|
||
//} | ||
} | ||
} |