Skip to content

Commit

Permalink
Merge pull request #19 from alzimmermsft/AzStorage_Blobs_Verify_Tests
Browse files Browse the repository at this point in the history
Fix linting error reporting and cleaned up more tests
  • Loading branch information
alzimmermsft authored Jun 28, 2019
2 parents 1343f5e + 25ed916 commit e3a8e37
Show file tree
Hide file tree
Showing 7 changed files with 118 additions and 854 deletions.
31 changes: 31 additions & 0 deletions storage/client/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -127,4 +127,35 @@
</plugin>
</plugins>
</build>

<reporting>
<plugins>
<!-- Now that all checkstyle issues have been resolved, override the
default behavior to make checkstyle fail on error and violation. -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-checkstyle-plugin</artifactId>
<configuration>
<failsOnError>false</failsOnError>
<failOnViolation>false</failOnViolation>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<configuration>
<failOnError>false</failOnError>
<failOnWarnings>false</failOnWarnings>
</configuration>
</plugin>

<plugin>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<configuration>
<failOnError>false</failOnError>
</configuration>
</plugin>
</plugins>
</reporting>
</project>
Original file line number Diff line number Diff line change
Expand Up @@ -144,19 +144,6 @@ class AppendBlobAPITest extends APISpec {
null | null | null | null | garbageLeaseID
}

/*def "Create context"() {
setup:
def pipeline = HttpPipeline.build(getStubFactory(getContextStubPolicy(201, AppendBlobCreateHeaders)))
bu = bu.withPipeline(pipeline)
when:
bu.create(null, null, null, defaultContext)
then:
notThrown(RuntimeException)
}*/

def "Append block defaults"() {
setup:
Response<AppendBlobItem> appendResponse = bu.appendBlock(defaultInputStream.get(), defaultDataSize)
Expand Down Expand Up @@ -191,6 +178,7 @@ class AppendBlobAPITest extends APISpec {
data | dataSize | exceptionType
null | defaultDataSize | NullPointerException
defaultInputStream.get() | defaultDataSize + 1 | IndexOutOfBoundsException
// This doesn't error as it isn't reading the entire stream which is valid in the new client
//defaultInputStream.get() | defaultDataSize - 1 | StorageException
}

Expand Down Expand Up @@ -288,19 +276,6 @@ class AppendBlobAPITest extends APISpec {
thrown(StorageException)
}

/*def "Append block context"() {
setup:
def pipeline = HttpPipeline.build(getStubFactory(getContextStubPolicy(201, AppendBlobAppendBlockHeaders)))
bu = bu.withPipeline(pipeline)
when:
bu.appendBlock(defaultFlowable, defaultDataSize, null, defaultContext)
then:
notThrown(RuntimeException)
}*/

def "Append block from URL min"() {
setup:
cu.setAccessPolicy(PublicAccessType.CONTAINER, null)
Expand Down Expand Up @@ -372,20 +347,6 @@ class AppendBlobAPITest extends APISpec {
thrown(StorageException)
}

/*def "Append block from URL context"() {
setup:
def pipeline = HttpPipeline.build(getStubFactory(getContextStubPolicy(201, AppendBlobAppendBlockFromUrlHeaders)))
bu = bu.withPipeline(pipeline)
when:
// No service call is made. Just satisfy the parameters.
bu.appendBlockFromUrl(bu.toURL(), null, null, null,null, defaultContext)
then:
notThrown(RuntimeException)
}*/

@Unroll
def "Append block from URL destination AC"() {
setup:
Expand Down
Loading

0 comments on commit e3a8e37

Please sign in to comment.