summaryrefslogtreecommitdiff
path: root/pharo-mooc/contact-book/src/ContactBook/ContactTest.class.st
blob: c1dc553ab08804e702eb9027825650e106256945 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
Class {
	#name : 'ContactTest',
	#superclass : 'TestCase',
	#category : 'ContactBook',
	#package : 'ContactBook'
}

{ #category : 'tests' }
ContactTest >> testCreation [

	| contact |
	contact := Contact
		newNamed: 'Marcus Denker'
		email: 'marcus.denker@inria.fr'.
	self assert: contact fullname equals: 'Marcus Denker'.
	self assert: contact email equals: 'marcus.denker@inria.fr'
]

{ #category : 'tests' }
ContactTest >> testPrinting [

	| contact |
	contact := Contact
		newNamed: 'Marcus Denker'
		email: 'marcus.denker@inria.fr'.
	self assert: contact asString equals: 'Marcus Denker <marcus.denker@inria.fr>'
]