or
or
By clicking below, you agree to our terms of service.
New to HackMD? Sign up
Syntax | Example | Reference | |
---|---|---|---|
# Header | Header | 基本排版 | |
- Unordered List |
|
||
1. Ordered List |
|
||
- [ ] Todo List |
|
||
> Blockquote | Blockquote |
||
**Bold font** | Bold font | ||
*Italics font* | Italics font | ||
~~Strikethrough~~ | |||
19^th^ | 19th | ||
H~2~O | H2O | ||
++Inserted text++ | Inserted text | ||
==Marked text== | Marked text | ||
[link text](https:// "title") | Link | ||
 | Image | ||
`Code` | Code |
在筆記中貼入程式碼 | |
```javascript var i = 0; ``` |
|
||
:smile: | ![]() |
Emoji list | |
{%youtube youtube_id %} | Externals | ||
$L^aT_eX$ | LaTeX | ||
:::info This is a alert area. ::: |
This is a alert area. |
On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?
Please give us some advice and help us improve HackMD.
Do you want to remove this version name and description?
Syncing
xxxxxxxxxx
Week 8
Developer Testing
@Test
annotation.Assert.assertEquals(expected, actual)
methods to compare the expected output with the actual output. If they do not match, the test will fail. JUnit comes with other similar methods such asAssert.assertNull
andAssert.assertTrue
.testStringConversion
but when writing test methods, sometimes another convention is used:whatIsBeingTested_descriptionOfTestInputs_expectedOutcome
e.g.,intDivision_zeroDivisor_exceptionThrown
Writing Developer Documents
is learning-oriented
allows the newcomer to get started
is a lesson
Analogy: teaching a small child how to cook
is goal-oriented
shows how to solve a specific problem
is a series of steps
Analogy: a recipe in a cookery book
is understanding-oriented
explains
provides background and context
Analogy: an article on culinary social history
is information-oriented
describes the machinery
is accurate and complete
Analogy: a reference encyclopedia article
Design: Models
Class/Object Diagrams: Basics
Class Diagrams
+
: public-
: private#
: protected~
: package privateLabels
Roles
-This association represents a marriage between a Man object and a Woman object. The respective roles played by objects of these two classes are husband and wife.
Multiplicity
Implementing multiplicity
0..1
multiplicity (also called optional associations) because a variable can hold a reference to a single object ornull
.0..1
: optional, can be linked to 0 or 1 objects1
: compulsory, must be linked to one object at all times.*
: can be linked to 0 or more objects.n..m
: the number of linked objects must be n to m inclusiveNavigability
Object Diagrams
car1:Car
are underlined.objectName:ClassName
is meant to say 'an instance ofClassName
identified asobjectName
'.Associations as Attributes
name: type [multiplicity] = default value
Notes
Project Mgt: Scheduling and Tracking
Buffer
Issue tracker
Work Breakdown Structure