Skip to content

Commit

Permalink
Add addTransformation support
Browse files Browse the repository at this point in the history
  • Loading branch information
adimiz1 authored Jun 27, 2023
1 parent 7a52a8e commit 29046f2
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
4 changes: 4 additions & 0 deletions url_gen/lib/transformation/transformation.dart
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,10 @@ class Transformation {
return add(GenericAction(transformation));
}

Transformation addTransformation(String transformation) {
return add(GenericAction(transformation));
}

Transformation resize(Resize resize) {
return add(resize);
}
Expand Down
3 changes: 3 additions & 0 deletions url_gen/test/transformation/trasnformation_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,9 @@ void main() {
test('Test successful generic transformation formatting', () {
cldAssert('a_0', Transformation()..generic('a_0'));
});
test('Test successful add transformations formatting', () {
cldAssert('a_0', Transformation()..addTransformation('a_0'));
});
test('Test successful named transformation formatting', () {
cldAssert("t_named", Transformation().namedTransformation('named'));
cldAssert(
Expand Down

0 comments on commit 29046f2

Please sign in to comment.