test-unit 3.2.3 → 3.2.4

Sign up to get free protection for your applications and to get access to all the features.
@@ -1197,6 +1197,80 @@ module Test
1197
1197
  assert_equal([:startup, :shutdown],
1198
1198
  test_case.called)
1199
1199
  end
1200
+
1201
+ class TestName < self
1202
+ def test_no_data
1203
+ test_case = Class.new(TestCase) do
1204
+ class << self
1205
+ def name
1206
+ "TestCase"
1207
+ end
1208
+ end
1209
+
1210
+ def test_nothing
1211
+ end
1212
+ end
1213
+
1214
+ test = test_case.new("test_nothing")
1215
+ assert_equal("test_nothing(TestCase)",
1216
+ test.name)
1217
+ end
1218
+
1219
+ def test_data
1220
+ test_case = Class.new(TestCase) do
1221
+ class << self
1222
+ def name
1223
+ "TestCase"
1224
+ end
1225
+ end
1226
+
1227
+ def test_nothing
1228
+ end
1229
+ end
1230
+
1231
+ test = test_case.new("test_nothing")
1232
+ test.assign_test_data("(nil)", nil)
1233
+ assert_equal("test_nothing[(nil)](TestCase)",
1234
+ test.name)
1235
+ end
1236
+ end
1237
+
1238
+ class TestLocalName < self
1239
+ def test_no_data
1240
+ test_case = Class.new(TestCase) do
1241
+ class << self
1242
+ def name
1243
+ "TestCase"
1244
+ end
1245
+ end
1246
+
1247
+ def test_nothing
1248
+ end
1249
+ end
1250
+
1251
+ test = test_case.new("test_nothing")
1252
+ assert_equal("test_nothing",
1253
+ test.local_name)
1254
+ end
1255
+
1256
+ def test_data
1257
+ test_case = Class.new(TestCase) do
1258
+ class << self
1259
+ def name
1260
+ "TestCase"
1261
+ end
1262
+ end
1263
+
1264
+ def test_nothing
1265
+ end
1266
+ end
1267
+
1268
+ test = test_case.new("test_nothing")
1269
+ test.assign_test_data("(nil)", nil)
1270
+ assert_equal("test_nothing[(nil)]",
1271
+ test.local_name)
1272
+ end
1273
+ end
1200
1274
  end
1201
1275
  end
1202
1276
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: test-unit
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.2.3
4
+ version: 3.2.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kouhei Sutou
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2016-11-25 00:00:00.000000000 Z
12
+ date: 2017-05-23 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: power_assert
@@ -113,6 +113,7 @@ files:
113
113
  - PSFL
114
114
  - README.md
115
115
  - Rakefile
116
+ - doc/text/getting-started.md
116
117
  - doc/text/how-to.md
117
118
  - doc/text/news.md
118
119
  - lib/test-unit.rb